]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[65-libyang-testutils] Cosmetics (trailing dots) and a '>>'
authorFrancis Dupont <fdupont@isc.org>
Tue, 23 Oct 2018 20:05:14 +0000 (22:05 +0200)
committerFrancis Dupont <fdupont@isc.org>
Wed, 24 Oct 2018 13:50:51 +0000 (15:50 +0200)
src/lib/yang/tests/adaptor_config_unittests.cc
src/lib/yang/tests/translator_utils_unittests.cc
src/lib/yang/tests/yang_configs.h
src/lib/yang/testutils/translator_test.h

index 6a86b0ad33566b91888edd33e66ef80ad54a95f1..6f1eb9017e2373dc8c045e5b4a578c6a9da695ef 100644 (file)
@@ -82,7 +82,7 @@ TEST_F(AdaptorConfigTest, loadExamples4) {
                                "with-ddns.json" };
 
     ElementPtr x;
-    
+
     for (int i = 0; i<configs.size(); i++) {
         x.reset();
         testFile(string(CFG_EXAMPLES) + "/kea4/" + configs[i], false, x);
@@ -113,7 +113,7 @@ TEST_F(AdaptorConfigTest, loadExamples6) {
                                "stateless.json",
                                "with-ddns.json" };
     ElementPtr x;
-    
+
     for (int i = 0; i<configs.size(); i++) {
         x.reset();
         testFile(string(CFG_EXAMPLES) + "/kea6/" + configs[i], true, x);
index 103f1f6b6da58a0963013c794fb731ff8f4838fe..cea5081d121ff71114554de3dd81d304360fdd44 100644 (file)
@@ -202,13 +202,12 @@ TEST(YangReprTest, setTest) {
     EXPECT_TRUE(repr.verify(testTree, sess, cerr));
 }
 
-
 /// @brief Tests specified configuration.
 ///
 /// Configuration is set and then verified using YangRepr object.
 ///
-/// @param model name of the model to be verified against
-/// @param tree tree to be verified
+/// @param model name of the model to be verified against.
+/// @param tree tree to be verified.
 void sanityCheckConfig(const std::string& model, const YRTree& tree) {
     // Get a translator object to play with.
     S_Connection conn(new Connection("utils unittests"));
@@ -225,8 +224,8 @@ void sanityCheckConfig(const std::string& model, const YRTree& tree) {
     EXPECT_TRUE(result);
 }
 
-// This is test environment sanity check. It verifies that every configuration
-// defined in yang_configs.h is sane.
+// This is test environment sanity check. It verifies that all configuration
+// defined in yang_configs.h are sane.
 TEST(YangReprTest, verifyConfigs) {
     for (auto x : test_configs) {
         cout << "Testing tree for model " << x.first << endl;
@@ -234,5 +233,4 @@ TEST(YangReprTest, verifyConfigs) {
     }
 }
 
-
 }; // end of anonymous namespace
index 91cd3ae862dd9bf4b6f4ed634914c5984db62f07..0720077b8bdbef9de8bacbeba4e3fff97b1b127d 100644 (file)
@@ -442,20 +442,19 @@ const YRTree designExampleTree = {
       "disabled", SR_ENUM_T, true }
 };
 
-/// @brief Set of example configurations
-const std::vector<std::pair<std::string, YRTree>> test_configs =
+/// @brief Set of example configurations.
+const std::vector<std::pair<std::string, YRTree> > test_configs =
 {
-    { exampleModel, exampleTree },
-    { testModel, testTree },
-    { subnetTwoPoolsModelIetf6, subnetTwoPoolsTreeIetf6 },
-    { subnetTimersModel, subnetTimersIetf6 },
-    { validModelIetf6, validTreeIetf6 },
-    { subnetOptionsModelKeaDhcp4, subnetOptionsTreeKeaDhcp4 },
-    { subnetOptionsModelKeaDhcp6, subnetOptionsTreeKeaDhcp6 },
-    { designExampleModel, designExampleTree }
+    { exampleModel,                exampleTree },
+    { testModel,                   testTree },
+    { subnetTwoPoolsModelIetf6,    subnetTwoPoolsTreeIetf6 },
+    { subnetTimersModel,           subnetTimersIetf6 },
+    { validModelIetf6,             validTreeIetf6 },
+    { subnetOptionsModelKeaDhcp4,  subnetOptionsTreeKeaDhcp4 },
+    { subnetOptionsModelKeaDhcp6,  subnetOptionsTreeKeaDhcp6 },
+    { designExampleModel,          designExampleTree }
 };
 
-
 }; // end of namespace isc::yang::test
 }; // end of namespace isc::yang
 }; // end of namespace isc
index 0cb5f8b1a913abf913bd20558b1f6e8fff763573..11352865fe2e264fb8c9830e17e6aa976e0aa0f5 100644 (file)
@@ -41,11 +41,11 @@ public:
             : xpath_(xpath), value_(value), type_(type), settable_(settable) {
         }
 
-        /// @brief Retrieves configuration parameter from sysrepo
+        /// @brief Retrieves configuration parameter from sysrepo.
         ///
-        /// @param xpath The xpath of an element to be retrieved
+        /// @param xpath The xpath of an element to be retrieved.
         /// @param session Sysrepo session.
-        /// @return YangReprItem instance representing configuration parameter
+        /// @return YangReprItem instance representing configuration parameter.
         static YangReprItem get(const std::string& xpath, S_Session session);
 
         /// @brief The xpath.
@@ -62,8 +62,8 @@ public:
 
         /// @brief The equal operator ignoring settable.
         ///
-        /// @param other the other object to compare with
-        /// @return true if equal
+        /// @param other the other object to compare with.
+        /// @return true if equal.
         bool operator==(const YangReprItem& other) const {
             return ((xpath_ == other.xpath_) &&
                     (value_ == other.value_) &&
@@ -72,8 +72,8 @@ public:
 
         /// @brief The unequal operator ignoring settable.
         ///
-        /// @param other the other object to compare with
-        /// @return false if equal
+        /// @param other the other object to compare with.
+        /// @return false if equal.
         bool operator!=(const YangReprItem& other) const {
             return (!(*this == other));
         }
@@ -92,7 +92,7 @@ public:
     /// @param expected The expected value.
     /// @param session Sysrepo session.
     /// @param errs Error stream.
-    /// @return true if verification succeeds, false with errors displayed
+    /// @return true if verification succeeds, false with errors displayed.
     /// on errs if it fails.
     bool verify(const Tree& expected, S_Session session,
                 std::ostream& errs) const;