Selenium IDE: How to create a script to run before / after each test case in this test suite?

I am looking for something that is equivalent to JUnit setUp()and methods tearDown(). In other words: I have a test suite; I would like to write a test installation example and a test test. An installation instance will be executed before each test in the package. A test drive will be executed after each test in the package.

How?

+3
source share
3 answers

It sounds as if you are at the point where you need to export tests from Selenium IDE to another format / language. The Selenium IDE is great for quickly prototyping tests or for demonstrating what Selenium can do, but when you actually start building a test library, you need to use a real programming language. Setup and Teardown are part of every core test suite (you mentioned JUnit, but also TestNG, NUnit and MSTest for C #, etc.), so use one! Using a real programming language also allows you to reorganize your tests, extracting the general functionality into classes, so that when you change your application in the test, you need to change one method, and not 100 tests. Most test systems also support some kind of data-based testing,which many Selenium users find useful.

+1

Java- ?

# Selenium MbUnit, Team City .

0

Robot Framework. Selenium, Robot Framework, Selenium, .

Robot Framework Test Setup , . Test Teardown .

0

All Articles