tests REFACTOR remove (mark) the unnecesarry tests on int8
Mark the original tests inside the tests blocks which are now replaced
bya separated tests for int8 base type
diff --git a/tests/utests/data/test_printer_xml.c b/tests/utests/data/test_printer_xml.c
index 521f0d6..f43c2a8 100644
--- a/tests/utests/data/test_printer_xml.c
+++ b/tests/utests/data/test_printer_xml.c
@@ -108,11 +108,14 @@
struct lyd_node *tree;
const char *data, *result;
+ #if 0
+ /* test on print int8 is in file ./tests/utests/types/int8.c */
data = "<int8 xmlns=\"urn:tests:types\">\n 15 \t\n </int8>";
result = "<int8 xmlns=\"urn:tests:types\">15</int8>";
CHECK_PARSE_LYD(data, 0, LYD_VALIDATE_PRESENT, tree);
CHECK_LYD_STRING(tree, LYD_PRINT_SHRINK | LYD_PRINT_WITHSIBLINGS, result);
lyd_free_all(tree);
+ #endif
}
static void
diff --git a/tests/utests/data/test_types.c b/tests/utests/data/test_types.c
index 80f6c86..8c47f32 100644
--- a/tests/utests/data/test_types.c
+++ b/tests/utests/data/test_types.c
@@ -142,6 +142,8 @@
const char *data;
char *error_msg;
+#if 0
+ /* type int8 is tested in file ./tests/utests/types/int8.c */
/* valid data */
data = "<int8 xmlns=\"urn:tests:types\">\n 15 \t\n </int8>";
CHECK_PARSE_LYD(data, tree);
@@ -153,6 +155,8 @@
/* invalid range */
error_msg = "Value \"1\" does not satisfy the range constraint.";
TEST_TYPE_ERROR("int8", "1", error_msg, "1");
+#endif
+
error_msg = "Value \"100\" does not satisfy the range constraint.";
TEST_TYPE_ERROR("int16", "100", error_msg, "1");
diff --git a/tests/utests/schema/test_parser_yang.c b/tests/utests/schema/test_parser_yang.c
index 8b60689..974f540 100644
--- a/tests/utests/schema/test_parser_yang.c
+++ b/tests/utests/schema/test_parser_yang.c
@@ -899,11 +899,17 @@
&d, "1", lysp_deviate_free(YCTX->parsed_mod->mod->ctx, d); free(d); d = NULL)
TEST_DUP("add", "config", "true", "false");
+#if 0
+ /*test on int8 now is in file tests/utest/types/int8.c */
TEST_DUP("replace", "default", "int8", "uint8");
+#endif
TEST_DUP("add", "mandatory", "true", "false");
TEST_DUP("add", "max-elements", "1", "2");
TEST_DUP("add", "min-elements", "1", "2");
+#if 0
+ /*test on int8 now is in file tests/utest/types/int8.c*/
TEST_DUP("replace", "type", "int8", "uint8");
+#endif
TEST_DUP("add", "units", "kilometers", "miles");
/* full contents */
diff --git a/tests/utests/schema/test_tree_schema_compile.c b/tests/utests/schema/test_tree_schema_compile.c
index 6ce0c6d..f81a6f1 100644
--- a/tests/utests/schema/test_tree_schema_compile.c
+++ b/tests/utests/schema/test_tree_schema_compile.c
@@ -678,6 +678,8 @@
const struct lys_module *mod;
struct lysc_type *type;
+#if 0
+ /*test about int8 should be in tests/utests/types/int8.c*/
assert_int_equal(LY_SUCCESS, lys_parse_mem(UTEST_LYCTX, "module a {namespace urn:a;prefix a;leaf l {type int8 {range min..10|max;}}}", LYS_IN_YANG, &mod));
type = ((struct lysc_node_leaf *)mod->compiled->data)->type;
assert_non_null(type);
@@ -689,6 +691,7 @@
assert_int_equal(10, ((struct lysc_type_num *)type)->range->parts[0].max_64);
assert_int_equal(127, ((struct lysc_type_num *)type)->range->parts[1].min_64);
assert_int_equal(127, ((struct lysc_type_num *)type)->range->parts[1].max_64);
+#endif
assert_int_equal(LY_SUCCESS, lys_parse_mem(UTEST_LYCTX, "module b {namespace urn:b;prefix b;leaf l {type int16 {range min..10|max;}}}", LYS_IN_YANG, &mod));
type = ((struct lysc_node_leaf *)mod->compiled->data)->type;