| Modifier and Type | Class and Description |
|---|---|
| public static class |
| Modifier and Type | Field and Description |
|---|---|
| private String | |
| private JUnitReportHelper. | |
| private JUnitReportWriter. | |
| private final boolean | |
| private String | |
| private boolean | |
| private JUnitReportWriter |
| Access | Constructor and Description |
|---|---|
| public | JUnitReportHelper(String
The class name of the class for this test cname)Prepare to generate a JUnitReport in the file named ${junit.report.dir}/${name}.xml. |
| Modifier and Type | Method and Description |
|---|---|
| private void | |
| public JUnitReportHelper. | |
| public void | |
| public void | |
| public void | |
| public void | |
| private void | |
| public void | |
| public void | |
| public void |
| className | back to summary |
|---|---|
| private String className | |
| counts | back to summary |
|---|---|
| private JUnitReportHelper. | |
| current | back to summary |
|---|---|
| private JUnitReportWriter. | |
| DEBUG | back to summary |
|---|---|
| private final boolean DEBUG | |
| fileName | back to summary |
|---|---|
| private String fileName | |
| testComplete | back to summary |
|---|---|
| private boolean testComplete | |
| writer | back to summary |
|---|---|
| private JUnitReportWriter writer | |
| JUnitReportHelper | back to summary |
|---|---|
| public JUnitReportHelper(String cname) Prepare to generate a JUnitReport in the file named ${junit.report.dir}/${name}.xml. junit.report.dir is obtained from the environment variable which is passed to all CTF controllers.
| |
| checkCurrent | back to summary |
|---|---|
| private void checkCurrent() | |
| done | back to summary |
|---|---|
| public JUnitReportHelper. Testing is complete. Calls to start, pass, or fail after this call will result in an IllegalStateException. This method may be called multiple times, but only the first call will write a report. | |
| fail | back to summary |
|---|---|
| public void fail(String msg) Report that the current test failed with an error message. | |
| fail | back to summary |
|---|---|
| public void fail(Throwable thr) Report that the current test failed with the given exception as cause. | |
| fail | back to summary |
|---|---|
| public void fail(String msg, long duration) Report that the current test failed with an error message. | |
| fail | back to summary |
|---|---|
| public void fail(Throwable thr, long duration) Report that the current test failed with the given exception as cause. | |
| msg | back to summary |
|---|---|
| private void msg(String str) | |
| pass | back to summary |
|---|---|
| public void pass() Report that the current test passed. | |
| pass | back to summary |
|---|---|
| public void pass(long duration) Report that the current test passed. | |
| start | back to summary |
|---|---|
| public void start(String name) Start executing a test case with the given name. All names MUST be unique for an instance of JUnitReportHelper.
| |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public int | |
| public int |
| Counts | back to summary |
|---|---|
| pack-priv Counts(int numPass, int numFail) | |
| numFail | back to summary |
|---|---|
| public int numFail() | |
| numPass | back to summary |
|---|---|
| public int numPass() | |