]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[#2658] address review comments
authorAndrei Pavel <andrei@isc.org>
Wed, 17 May 2023 16:09:39 +0000 (19:09 +0300)
committerAndrei Pavel <andrei@isc.org>
Wed, 17 May 2023 16:09:39 +0000 (19:09 +0300)
src/bin/dhcp4/tests/fqdn_unittest.cc
src/lib/cc/data.h

index 2b87a360a161a67f634e67b689d5e488b8f8d04b..0ad951ada094d88a546cc3c6bf1edd6cfe5bf4c5 100644 (file)
@@ -908,21 +908,6 @@ public:
         ASSERT_TRUE(obs) << "cannot find: " << stats_name;
         EXPECT_EQ(exp_value, obs->getInteger().first);
     }
-
-    /// @brief Checks the value of a big integer statistic for a given subnet.
-    ///
-    /// @param subnet_id identifier of a subnet for which the statistic should be checked
-    /// @param name statistic name (e.g. "total-nas", "total-pds", ...)
-    /// @param exp_value expected value of the statistic
-    ///
-    /// @return Number of assigned addresses for a subnet.
-    void checkBigSubnetStat(const SubnetID& subnet_id, const std::string& name, int64_t exp_value) const {
-        // Retrieve statistics name, e.g. subnet[1234].assigned-addresses.
-        const std::string stats_name = StatsMgr::generateName("subnet", subnet_id, name);
-        ObservationPtr obs =  StatsMgr::instance().getObservation(stats_name);
-        ASSERT_TRUE(obs) << "cannot find: " << stats_name;
-        EXPECT_EQ(exp_value, obs->getBigInteger().first);
-    }
 };
 
 // Tests the following scenario:
index 6e29f2fbf202fb1485c3166b1aa1b51a36982b37..e954ea9009d7d1001f7535f24ac11b0731f24b0b 100644 (file)
@@ -215,7 +215,8 @@ public:
 
     /// @name pure virtuals, every derived class must implement these
 
-    /// @return true if the other ElementPtr has the same type and value
+    /// @return true if the other ElementPtr has the same value and the same
+    /// type (or a different and compatible type), false otherwise.
     virtual bool equals(const Element& other) const = 0;
 
     /// Converts the Element to JSON format and appends it to
@@ -656,7 +657,10 @@ public:
     /// stringstream.
     void toJSON(std::ostream& ss) const override;
 
-    /// @brief Checks whether the other Element has the same type and value.
+    /// @brief Checks whether the other Element is equal.
+    ///
+    /// @return true if the other ElementPtr has the same value and the same
+    /// type (or a different and compatible type), false otherwise.
     bool equals(const Element& other) const override;
 
 private: