Skip to content

Commit d07dd6f

Browse files
author
jmarkerink
committed
fix: unittests
1 parent f2869e6 commit d07dd6f

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

test-common/src/main/java/de/bwaldvogel/mongo/backend/AbstractBackendTest.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2468,7 +2468,7 @@ private static String repeat(String str, int num) {
24682468

24692469
@Test
24702470
public void testServerStatus() {
2471-
verifyServerStatus(runCommand("serverStatus"));
2471+
verifyServerStatus(runCommand(Command.SERVER_STATUS));
24722472
verifyServerStatus(getDatabase().runCommand(json("serverStatus:1")));
24732473
}
24742474

@@ -3795,7 +3795,7 @@ void testUpdateWithIllegalMultiplyFails() {
37953795

37963796
@Test
37973797
void testIsMaster() {
3798-
Document isMaster = runCommand("isMaster");
3798+
Document isMaster = runCommand(Command.IS_MASTER);
37993799
assertThat(isMaster.getBoolean("ismaster")).isTrue();
38003800
assertThat(isMaster.getDate("localTime")).isInstanceOf(Date.class);
38013801
Integer maxBsonObjectSize = isMaster.getInteger("maxBsonObjectSize");
@@ -6638,27 +6638,27 @@ void testUuidRepresentations(UuidRepresentation uuidRepresentation) {
66386638

66396639
@Test
66406640
void testConnectionStatus() {
6641-
Document result = runCommand("connectionStatus");
6641+
Document result = runCommand(Command.CONNECTION_STATUS);
66426642
assertThat(result).isEqualTo(json("ok: 1.0, authInfo: {authenticatedUsers: [], authenticatedUserRoles: []}"));
66436643
}
66446644

66456645
@Test
66466646
void testHostInfo() {
6647-
Document result = runCommand("hostInfo");
6647+
Document result = runCommand(Command.HOST_INFO);
66486648
assertThat(result.get("ok")).isEqualTo(1.0);
66496649
assertThat(result).containsKeys("os", "system", "extra");
66506650
}
66516651

66526652
@Test
66536653
void testGetCmdLineOpts() {
6654-
Document result = runCommand("getCmdLineOpts");
6654+
Document result = runCommand(Command.GET_CMD_LINE_OPTS);
66556655
assertThat(result.get("ok")).isEqualTo(1.0);
66566656
assertThat(result).containsOnlyKeys("ok", "argv", "parsed");
66576657
}
66586658

66596659
@Test
66606660
void testGetFreeMonitoringStatus() {
6661-
Document result = runCommand("getFreeMonitoringStatus");
6661+
Document result = runCommand(Command.GET_FREE_MONITORING_STATUS);
66626662
assertThat(result).isEqualTo(json("ok: 1.0, state: 'disabled', debug: {state: 'undecided'}," +
66636663
" message: 'Free monitoring is deprecated, refer to \\'debug\\' field for actual status'"));
66646664
}

0 commit comments

Comments
 (0)