Revert "test: add test for prefix unit loading" 82/236082/3 submit/tizen/20200617.084905
authorAdrian Szyndela <adrian.s@samsung.com>
Fri, 12 Jun 2020 13:06:54 +0000 (15:06 +0200)
committerHyotaek Shim <hyotaek.shim@samsung.com>
Wed, 17 Jun 2020 08:38:44 +0000 (08:38 +0000)
This reverts commit 7ce49e656b1377713ade999dfe381807a78313cd.

The previous revert (6927aa2bc09726ff1f071770a8ce0c2ea6430b6b)
reverts more than it is described within its description. As it is
a base for some of subsequent commits in the upstream, they are
silently removed, probably because of conflict resolving.

Prefix unit loading is a feature that is a victim of such silent removal.
Therefore, the feature test is also (temporarily, I hope) removed with
this commit.

Change-Id: Ie82e5a54852ea08c8b3f0561f304fab6f3434aaf

src/test/test-engine.c
test/meson.build
test/unit-.service.d/10-override.conf [deleted file]
test/unit-with-.service.d/20-override.conf [deleted file]
test/unit-with-multiple-.service.d/20-override.conf [deleted file]
test/unit-with-multiple-.service.d/30-override.conf [deleted file]
test/unit-with-multiple-dashes.service [deleted file]
test/unit-with-multiple-dashes.service.d/10-override.conf [deleted file]

index b835114..9159abf 100644 (file)
@@ -15,7 +15,7 @@ int main(int argc, char *argv[]) {
         _cleanup_(sd_bus_error_free) sd_bus_error err = SD_BUS_ERROR_NULL;
         _cleanup_(manager_freep) Manager *m = NULL;
         Unit *a = NULL, *b = NULL, *c = NULL, *d = NULL, *e = NULL, *g = NULL,
-             *h = NULL, *i = NULL, *a_conj = NULL, *unit_with_multiple_dashes = NULL;
+             *h = NULL, *i = NULL, *a_conj = NULL;
         Job *j;
         int r;
 
@@ -146,10 +146,5 @@ int main(int argc, char *argv[]) {
         assert_se(!hashmap_get(a->dependencies[UNIT_PROPAGATES_RELOAD_TO], c));
         assert_se(!hashmap_get(c->dependencies[UNIT_RELOAD_PROPAGATED_FROM], a));
 
-        assert_se(manager_load_unit(m, "unit-with-multiple-dashes.service", NULL, NULL, &unit_with_multiple_dashes) >= 0);
-
-        assert_se(strv_equal(unit_with_multiple_dashes->documentation, STRV_MAKE("man:test", "man:override2", "man:override3")));
-        assert_se(streq_ptr(unit_with_multiple_dashes->description, "override4"));
-
         return 0;
 }
index cbd99b5..8310c39 100644 (file)
@@ -194,18 +194,13 @@ test_data_files = '''
         test-path/path-unit.path
         test-path/paths.target
         test-path/sysinit.target
-        test-umount/empty.mountinfo
-        test-umount/example.swaps
-        test-umount/garbled.mountinfo
-        test-umount/rhbug-1554943.mountinfo
         testsuite.target
         timers.target
-        unit-with-.service.d/20-override.conf
-        unit-with-multiple-.service.d/20-override.conf
-        unit-with-multiple-.service.d/30-override.conf
-        unit-with-multiple-dashes.service
-        unit-with-multiple-dashes.service.d/10-override.conf
         unstoppable.service
+        test-umount/empty.mountinfo
+        test-umount/garbled.mountinfo
+        test-umount/rhbug-1554943.mountinfo
+        test-umount/example.swaps
 '''.split()
 
 if conf.get('ENABLE_RESOLVE') == 1
diff --git a/test/unit-.service.d/10-override.conf b/test/unit-.service.d/10-override.conf
deleted file mode 100644 (file)
index 916737d..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-[Unit]
-Description=override0
diff --git a/test/unit-with-.service.d/20-override.conf b/test/unit-with-.service.d/20-override.conf
deleted file mode 100644 (file)
index c6c2438..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-[Unit]
-Documentation=man:override1
diff --git a/test/unit-with-multiple-.service.d/20-override.conf b/test/unit-with-multiple-.service.d/20-override.conf
deleted file mode 100644 (file)
index 62fafd2..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-[Unit]
-Documentation=man:override2
diff --git a/test/unit-with-multiple-.service.d/30-override.conf b/test/unit-with-multiple-.service.d/30-override.conf
deleted file mode 100644 (file)
index b9616da..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-[Unit]
-Documentation=man:override3
diff --git a/test/unit-with-multiple-dashes.service b/test/unit-with-multiple-dashes.service
deleted file mode 100644 (file)
index b38b360..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-[Unit]
-Description=A unit with multiple dashes
-Documentation=man:test
-
-[Service]
-ExecStart=/bin/true
diff --git a/test/unit-with-multiple-dashes.service.d/10-override.conf b/test/unit-with-multiple-dashes.service.d/10-override.conf
deleted file mode 100644 (file)
index 982c362..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-[Unit]
-Description=override4