I am testing a website that can be redirected in several ways, one of which is incorrect in all cases (and one of them is correct depending on the context).
The most direct way I can tell the difference is to carefully examine the image loaded in a specific area.
I also notice that the paths of CSS files (as well as image files) vary depending on the scenario, so it may be easier to test the paths instead of the images themselves (they are all the same).
Unfortunately, I cannot share this code, but in general terms, how could you use a protractor to collect the full path data for a specific css file (or image) of the page and compare it with what is expected?
source
share