public class ResourceCheckerJUnitListener extends org.junit.runner.notification.RunListener
When surefire forkMode=once/always/perthread, this code is executed on the forked process.
Modifier and Type | Class and Description |
---|---|
(package private) static class |
ResourceCheckerJUnitListener.AvailableMemoryMBResourceAnalyzer |
(package private) static class |
ResourceCheckerJUnitListener.MaxFileDescriptorResourceAnalyzer |
(package private) static class |
ResourceCheckerJUnitListener.OpenFileDescriptorResourceAnalyzer |
(package private) static class |
ResourceCheckerJUnitListener.ProcessCountResourceAnalyzer |
(package private) static class |
ResourceCheckerJUnitListener.SystemLoadAverageResourceAnalyzer |
(package private) static class |
ResourceCheckerJUnitListener.ThreadResourceAnalyzer |
Modifier and Type | Field and Description |
---|---|
private Map<String,ResourceChecker> |
rcs |
Constructor and Description |
---|
ResourceCheckerJUnitListener() |
Modifier and Type | Method and Description |
---|---|
protected void |
addResourceAnalyzer(ResourceChecker rc)
To be implemented by sub classes if they want to add specific ResourceAnalyzer.
|
private String |
descriptionToShortTestName(org.junit.runner.Description description)
Get the test name from the JUnit Description
|
private void |
end(String testName) |
private void |
start(String testName) |
void |
testFinished(org.junit.runner.Description description) |
void |
testStarted(org.junit.runner.Description description) |
private Map<String,ResourceChecker> rcs
public ResourceCheckerJUnitListener()
protected void addResourceAnalyzer(ResourceChecker rc)
private String descriptionToShortTestName(org.junit.runner.Description description)
public void testStarted(org.junit.runner.Description description) throws Exception
testStarted
in class org.junit.runner.notification.RunListener
Exception
public void testFinished(org.junit.runner.Description description) throws Exception
testFinished
in class org.junit.runner.notification.RunListener
Exception
Copyright © 2007–2021 The Apache Software Foundation. All rights reserved.