In my software QA testing environment, we’ve tended to do E2E testing of every single possible scenario for our web app. I’ve been trying to make the testing more efficient, but I’m having trouble sorting out what should be an E2E test and what shouldn’t be. For instance, looking at Reddit as an example (using the Fancy Pants editor):
– Buttons for OC and Flair are disabled, based on a configuration setting. Would this be an E2E type test?
– Clicking the spoiler button changes the button appearance (so you would click that, submit a post, then check that the post got set to spoiler properly)
– Same thing as Spoiler button for NSFW button
I know from various reading and training that I’ve done that E2E type tests should be the smallest percentage of your tests (due to expense to write and maintain), and to leverage unit, API, and integration tests more. However, actually applying these things is a new thing for me, and I feel like I’m struggling without actually having a contextual example (for instance, some things that are shown in a UI could be sent by the backend server, so the client just receives it and processes it; or a button in the UI is enabled/disabled based on a given condition; or clicking a button just sends a request to a backend API and then the backend logic does whatever the button action is for the button that was clicked)
I hope it doesn’t sound like I’m rambling. Would appreciate any thoughts that others have based on their own experiences