3 ms·
There is no such thing as backwards compatible changes to button content If your form html is reasonably semantically structured, and/or you give meaningful ID
by nitrogen 5y ago
There is no such thing as backwards compatible changes to button content
If your form html is reasonably semantically structured, and/or you give meaningful IDs to each interactive element, then your tests can be made somewhat robust against content changes. E.g. "click button #next-step" rather than "click the word Next".
If your frontend is a desktop or mobile app, look for ways to introspect the widget hierarchy to do the same thing (I know this is possible in e.g. Swing).
- Vinnl 5y agoBut generally you'll want to emulate how users use your application, which is looking for a button with a particular label (bonus points if your tests are looking for the accessible label), rather than something with a given ID.