]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
test: move TEST-18-FAILUREACTION setup to static files
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 10 Dec 2019 07:27:33 +0000 (08:27 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sat, 28 Mar 2020 10:46:47 +0000 (11:46 +0100)
test/TEST-18-FAILUREACTION/test.sh
test/units/testsuite-18.service [new file with mode: 0644]
test/units/testsuite-18.sh [moved from test/TEST-18-FAILUREACTION/testsuite.sh with 100% similarity]

index b6231e6f5aec8f1422b018699302e9644f03bf00..a9315466f93cf64322810bbf31971c6bd37f5ec6 100755 (executable)
@@ -14,22 +14,9 @@ test_setup() {
 
         setup_basic_environment
         mask_supporting_services
-
-        # setup the testsuite service
-        cat >$initdir/etc/systemd/system/testsuite.service <<EOF
-[Unit]
-Description=Testsuite service
-
-[Service]
-ExecStart=/bin/bash -x /testsuite.sh
-Type=oneshot
-EOF
-        cp testsuite.sh $initdir/
-
-        setup_testsuite
     )
 
     setup_nspawn_root
 }
 
-do_test "$@"
+do_test "$@" 18
diff --git a/test/units/testsuite-18.service b/test/units/testsuite-18.service
new file mode 100644 (file)
index 0000000..08e8366
--- /dev/null
@@ -0,0 +1,6 @@
+[Unit]
+Description=TEST-18-FAILUREACTION
+
+[Service]
+ExecStart=/usr/lib/systemd/tests/testdata/units/%N.sh
+Type=oneshot