OO Selenium test cases?
Is it possible to import scripts to a selenium test case, when using the selenium IDE. For example all of my test cases will require a login. However I do not want to login on every test case. I would rather write one test case that is concerned with logging in and th开发者_开发百科en import this into all of the other test cases.
You can group you cases in a test suite and place your login case as the first one in that suite.
You could also load a external file with functions (e.g. login) in all test cases. Then you can run the login/logout function in every testcase.
include 'Testing/functions.php';
login($this);
.
.
.
logout($this);
精彩评论