Merge pull request #59 from das7pad/tests/cleanup-resources

[tests] cleanup resources
This commit is contained in:
Shane Kilkelly
2019-08-01 16:26:51 +01:00
committed by GitHub
5 changed files with 81 additions and 97 deletions

View File

@@ -47,6 +47,14 @@ public class MockSnapshotServer {
port = ((NetworkConnector) server.getConnectors()[0]).getLocalPort();
}
public void stop() {
try {
server.stop();
} catch (Exception e) {
Log.warn("Exception when trying to stop server", e);
}
}
public void setState(SnapshotAPIState state) {
responseBuilder.setState(state);
}