adspace


How do you Skip Test Case from execution?

Answer Posted / naazneen

There are two ways to skip a test case :

1. By using testNg annotation , enabled=false

Eg: @Test(enabled=false)
Public void testCase(){
// code
}

2. By using "Skip Exception"

Eg: @Test
public void testCase1(){
throw Skip Exception(" skipping the test ");
}

Is This Answer Correct ?    12 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can you fetch an attribute from an element? How to retrieve typed text from a textbox?

1197


what will be the first salary and what will be the hike in the salary?

929


Have you created any framework?

1039


What’s selenese?

920


Do you know how to locate a link using its text in selenium?

986