Skip to content

Instantly share code, notes, and snippets.

@kramer
Created July 9, 2013 06:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kramer/5955207 to your computer and use it in GitHub Desktop.
Save kramer/5955207 to your computer and use it in GitHub Desktop.
Conditionally igore JUnit test cases
public class ConditionallyIgnoreSampleTest {
@Test
public void sampleTest() {
// ignore test if OS is windows
Assume.assumeTrue(!SystemUtils.IS_OS_WINDOWS);
// assertions ...
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment