Skip to content

Instantly share code, notes, and snippets.

@freynaud
Created June 8, 2011 21:25
Show Gist options
  • Save freynaud/1015444 to your computer and use it in GitHub Desktop.
Save freynaud/1015444 to your computer and use it in GitHub Desktop.
beta
@DataProvider(name = "test1")
public Object[][] createData1() {
return new Object[][] { { "passed", true }, { "failed", false }, };
}
@Test( dataProvider = "test1")
public void m2(String a, boolean b) {
System.out.println("m2:" + a + "," + b);
if (!b) {
throw new RuntimeException("horrible bug");
}
}
@Test(dependsOnMethods = "m2", dataProvider = "test1")
public void m3(String a, boolean b) {
System.out.println("m3:" + a + "," + b);
}
@freynaud
Copy link
Author

freynaud commented Jun 8, 2011

m2:passed,true
m2:failed,false
PASSED: m2("passed", true)
FAILED: m2("failed", false)
java.lang.RuntimeException: horrible bug

SKIPPED: m3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment