Skip to content

Tag: testng

How to locate an element on this page?

I tried a lot to locate elements on this page with this link ALL I want to do is to select “1 queen bed” or “1 double large bed” and then select amount from the drop down list then press, I’ll reserve button. But I totally failed trying all of these:- using Action –> mov…

TestNG – how to run the same method at the end of each test

I have something like: and I would like to move Assert.assertFalse(errorsExists()) to BaseTestCase or to TestListener so I will not have to pass it every time at the end of the test. I tried to move it to TestsListener to onFinish but method errorsExists() requires driver and I have problems to get it in ther…

Batch File creation for selenium project

I need to create a .bat file to execute my selenium project that i created with TestNG. I created the .xml file: The problem is i have two @Test and for some reason he executes them as if in the same time since when he tries to login he puts the login values twice. for reference this is my .bat