Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
#827: Added slow unit test
- Loading branch information
Showing
2 changed files
with
43 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
package io.hawt.dummy; | ||
|
||
import org.junit.After; | ||
import org.junit.Before; | ||
import org.junit.Test; | ||
import org.slf4j.Logger; | ||
import org.slf4j.LoggerFactory; | ||
|
||
public class DummySlowTest { | ||
|
||
private static final Logger LOG = LoggerFactory.getLogger(DummySlowTest.class); | ||
|
||
@Before | ||
public void init() throws Exception { | ||
LOG.info("Init test"); | ||
} | ||
|
||
@After | ||
public void destroy() throws Exception { | ||
LOG.info("Destroy test"); | ||
} | ||
|
||
@Test | ||
public void testSlow() throws Exception { | ||
// TODO: detect mbean and only do if jmx detected | ||
for (int i = 0; i < 30; i++) { | ||
LOG.info("Testing slow method iteration {}", i); | ||
Thread.sleep(1000); | ||
} | ||
} | ||
|
||
} |