Skip to content

Instantly share code, notes, and snippets.

@shibli049
Created November 26, 2018 14:51
Show Gist options
  • Save shibli049/60915b141f9e2e60832e7474584dd322 to your computer and use it in GitHub Desktop.
Save shibli049/60915b141f9e2e60832e7474584dd322 to your computer and use it in GitHub Desktop.
@Test
@DisplayName("Time assertions")
@RepeatedTest(10)
public void timeAssertion(){
assertTimeout(Duration.ofSeconds(1), () -> {
Thread.sleep(100);
System.out.println("hello world!!");
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment