From: Marcin Siodelski Date: Fri, 6 Sep 2019 09:56:06 +0000 (+0200) Subject: [#755,!502] Removed duplicated test after the rebase. X-Git-Tag: Kea-1.7.0~26 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=92ffc5bc80bb954cb9a70ff129e8dfd3b90f0234;p=thirdparty%2Fkea.git [#755,!502] Removed duplicated test after the rebase. --- diff --git a/src/bin/dhcp6/tests/ctrl_dhcp6_srv_unittest.cc b/src/bin/dhcp6/tests/ctrl_dhcp6_srv_unittest.cc index d72888dcf3..41de6ff27c 100644 --- a/src/bin/dhcp6/tests/ctrl_dhcp6_srv_unittest.cc +++ b/src/bin/dhcp6/tests/ctrl_dhcp6_srv_unittest.cc @@ -553,80 +553,6 @@ TEST_F(CtrlChannelDhcpv6SrvTest, controlChannelShutdown) { EXPECT_EQ("{ \"result\": 0, \"text\": \"Shutting down.\" }",response); } -// Tests that the server properly responds to statistics commands. Note this -// is really only intended to verify that the appropriate Statistics handler -// is called based on the command. It is not intended to be an exhaustive -// test of Dhcpv6 statistics. -TEST_F(CtrlChannelDhcpv6SrvTest, controlChannelStats) { - createUnixChannelServer(); - std::string response; - - // Check statistic-get - sendUnixCommand("{ \"command\" : \"statistic-get\", " - " \"arguments\": {" - " \"name\":\"bogus\" }}", response); - EXPECT_EQ("{ \"arguments\": { }, \"result\": 0 }", response); - - // Check statistic-get-all - sendUnixCommand("{ \"command\" : \"statistic-get-all\", " - " \"arguments\": {}}", response); - EXPECT_EQ("{ \"arguments\": { }, \"result\": 0 }", response); - - // Check statistic-reset - sendUnixCommand("{ \"command\" : \"statistic-reset\", " - " \"arguments\": {" - " \"name\":\"bogus\" }}", response); - EXPECT_EQ("{ \"result\": 1, \"text\": \"No 'bogus' statistic found\" }", - response); - - // Check statistic-reset-all - sendUnixCommand("{ \"command\" : \"statistic-reset-all\", " - " \"arguments\": {}}", response); - EXPECT_EQ("{ \"result\": 0, \"text\": " - "\"All statistics reset to neutral values.\" }", response); - - // Check statistic-remove - sendUnixCommand("{ \"command\" : \"statistic-remove\", " - " \"arguments\": {" - " \"name\":\"bogus\" }}", response); - EXPECT_EQ("{ \"result\": 1, \"text\": \"No 'bogus' statistic found\" }", - response); - - // Check statistic-remove-all - sendUnixCommand("{ \"command\" : \"statistic-remove-all\", " - " \"arguments\": {}}", response); - EXPECT_EQ("{ \"result\": 0, \"text\": \"All statistics removed.\" }", - response); - - // Check statistic-sample-age-set - sendUnixCommand("{ \"command\" : \"statistic-sample-age-set\", " - " \"arguments\": {" - " \"name\":\"bogus\", \"duration\": 1245 }}", response); - EXPECT_EQ("{ \"result\": 1, \"text\": \"No 'bogus' statistic found\" }", - response); - - // Check statistic-sample-age-set-all - sendUnixCommand("{ \"command\" : \"statistic-sample-age-set-all\", " - " \"arguments\": {" - " \"duration\": 1245 }}", response); - EXPECT_EQ("{ \"result\": 0, \"text\": \"All statistics duration limit are set.\" }", - response); - - // Check statistic-sample-count-set - sendUnixCommand("{ \"command\" : \"statistic-sample-count-set\", " - " \"arguments\": {" - " \"name\":\"bogus\", \"max-samples\": 100 }}", response); - EXPECT_EQ("{ \"result\": 1, \"text\": \"No 'bogus' statistic found\" }", - response); - - // Check statistic-sample-count-set-all - sendUnixCommand("{ \"command\" : \"statistic-sample-count-set-all\", " - " \"arguments\": {" - " \"max-samples\": 100 }}", response); - EXPECT_EQ("{ \"result\": 0, \"text\": \"All statistics count limit are set.\" }", - response); -} - // Check that the "config-set" command will replace current configuration TEST_F(CtrlChannelDhcpv6SrvTest, configSet) { createUnixChannelServer();