Selenium tests tend to make a lot of use of assertions, to check that some actions have been performed on the front-end or that some WebElement properties are the expected ones. And by assertions, I mean, mostly: assertEquals or assertTrue, as these are the most commonly used ones. Assertions fail too often due to the… Read More
Context: you need to check that the values you have in a List of Strings are the same as the contents of a file. An element in the List will correspond to an entire line from the file. How can you achieve this easily?
When you have more than one assertion in your test, you might want one of two things: Have your tests fail once the first assertion failure is encountered. Have all your assertions run, no matter if they have passed or failed. Of course, after they are run, if there are failures, you want the test… Read More