From: Razvan Becheriu Date: Mon, 27 Apr 2020 19:06:12 +0000 (+0300) Subject: [#1188] fixed unittests X-Git-Tag: Kea-1.7.8~151 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ed504b1ce1ff75e8f615a65f9b5f72ca529e5347;p=thirdparty%2Fkea.git [#1188] fixed unittests --- diff --git a/src/bin/dhcp4/tests/ctrl_dhcp4_srv_unittest.cc b/src/bin/dhcp4/tests/ctrl_dhcp4_srv_unittest.cc index 753df545ef..9c403d382f 100644 --- a/src/bin/dhcp4/tests/ctrl_dhcp4_srv_unittest.cc +++ b/src/bin/dhcp4/tests/ctrl_dhcp4_srv_unittest.cc @@ -461,7 +461,8 @@ TEST_F(CtrlChannelDhcpv4SrvTest, libreload) { EXPECT_TRUE(checkMarkerFile(LOAD_MARKER_FILE, "1212")); } -// Check that the "libreload" command will reload libraries when MT is enabled +// Check that the "libreload" command will fail to reload libraries which are +// not compatible when multi-threading is enabled TEST_F(CtrlChannelDhcpv4SrvTest, libreloadFailMultiThreading) { createUnixChannelServer(); diff --git a/src/bin/dhcp4/tests/hooks_unittest.cc b/src/bin/dhcp4/tests/hooks_unittest.cc index 8f83e824ab..4e3d0ae858 100644 --- a/src/bin/dhcp4/tests/hooks_unittest.cc +++ b/src/bin/dhcp4/tests/hooks_unittest.cc @@ -2756,7 +2756,7 @@ TEST_F(LoadUnloadDhcpv4SrvTest, unloadLibraries) { } // Verifies that libraries incompatible with multi threading are not loaded by -// the server +// the server. // The callout libraries write their library index number to a marker // file upon load and unload, making it simple to test whether or not // the load and unload callouts have been invoked. diff --git a/src/bin/dhcp6/tests/ctrl_dhcp6_srv_unittest.cc b/src/bin/dhcp6/tests/ctrl_dhcp6_srv_unittest.cc index 9cec48651c..a90978dff2 100644 --- a/src/bin/dhcp6/tests/ctrl_dhcp6_srv_unittest.cc +++ b/src/bin/dhcp6/tests/ctrl_dhcp6_srv_unittest.cc @@ -475,7 +475,8 @@ TEST_F(CtrlChannelDhcpv6SrvTest, libreload) { EXPECT_TRUE(checkMarkerFile(LOAD_MARKER_FILE, "1212")); } -// Check that the "libreload" command will reload libraries when MT is enabled +// Check that the "libreload" command will fail to reload libraries which are +// not compatible when multi-threading is enabled TEST_F(CtrlChannelDhcpv6SrvTest, libreloadFailMultiThreading) { createUnixChannelServer(); diff --git a/src/bin/dhcp6/tests/hooks_unittest.cc b/src/bin/dhcp6/tests/hooks_unittest.cc index 985007734a..e6ff78b28a 100644 --- a/src/bin/dhcp6/tests/hooks_unittest.cc +++ b/src/bin/dhcp6/tests/hooks_unittest.cc @@ -4899,7 +4899,7 @@ TEST_F(LoadUnloadDhcpv6SrvTest, unloadLibraries) { } // Verifies that libraries incompatible with multi threading are not loaded by -// the server +// the server. // The callout libraries write their library index number to a marker // file upon load and unload, making it simple to test whether or not // the load and unload callouts have been invoked. diff --git a/src/lib/dhcpsrv/tests/multi_threading_config_parser_unittest.cc b/src/lib/dhcpsrv/tests/multi_threading_config_parser_unittest.cc index c5d938ffe6..1f3b994bbd 100644 --- a/src/lib/dhcpsrv/tests/multi_threading_config_parser_unittest.cc +++ b/src/lib/dhcpsrv/tests/multi_threading_config_parser_unittest.cc @@ -54,7 +54,7 @@ TEST_F(MultiThreadingConfigParserTest, validContent) { { "enable-multi-threading, without thread-pool-size or packet-queue-size", "{ \n" - " \"enable-multi-threading\": true, \n" + " \"enable-multi-threading\": true \n" "} \n" }, {