@TempDir
.
When a test with a temporary directory completes, it might be useful in
some cases to be able to view the contents of the temporary directory used by
the test. CleanupMode
allows you to control how a TempDir
is cleaned up.
TempDir
Modifier and Type | Field and Description |
---|---|
public static final CleanupMode | ALWAYS
Always clean up a temporary directory after the test has completed. |
public static final CleanupMode | DEFAULT
Use the default cleanup mode. |
public static final CleanupMode | NEVER
Never clean up a temporary directory after the test has completed. |
public static final CleanupMode | ON_SUCCESS
Only clean up a temporary directory if the test completed successfully. |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public static CleanupMode | |
public static CleanupMode[] |
ALWAYS | back to summary |
---|---|
public static final CleanupMode ALWAYS Always clean up a temporary directory after the test has completed. |
DEFAULT | back to summary |
---|---|
public static final CleanupMode DEFAULT Use the default cleanup mode. |
NEVER | back to summary |
---|---|
public static final CleanupMode NEVER Never clean up a temporary directory after the test has completed. |
ON_SUCCESS | back to summary |
---|---|
public static final CleanupMode ON_SUCCESS Only clean up a temporary directory if the test completed successfully. |
CleanupMode | back to summary |
---|---|
private CleanupMode() |
valueOf | back to summary |
---|---|
public static CleanupMode valueOf(String name) |
values | back to summary |
---|---|
public static CleanupMode[] values() |