Stop using CSS and Test Ids to locate elements in tests

How should we locate elements when testing web pages?