From c6cf339ecaf2fd1328b40c2432bba4f939d68045 Mon Sep 17 00:00:00 2001 From: Niels Thykier Date: Sat, 16 Dec 2017 15:39:41 +0000 Subject: dh_installsystemd: Enable dh_installsystemd in old compat levels Signed-off-by: Niels Thykier --- t/dh_installsystemd/dh_installsystemd.t | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) (limited to 't/dh_installsystemd') diff --git a/t/dh_installsystemd/dh_installsystemd.t b/t/dh_installsystemd/dh_installsystemd.t index 70133b97..f7e806ff 100755 --- a/t/dh_installsystemd/dh_installsystemd.t +++ b/t/dh_installsystemd/dh_installsystemd.t @@ -16,7 +16,7 @@ our @TEST_DH_EXTRA_TEMPLATE_FILES = (qw( )); if (uid_0_test_is_ok()) { - plan(tests => 2); + plan(tests => 1); } else { plan skip_all => 'fakeroot required'; } @@ -47,7 +47,7 @@ sub unit_is_started { } # Units are installed and enabled -each_compat_from_and_above_subtest(11, sub { +each_compat_subtest { ok(run_dh_tool({ 'needs_root' => 1 }, 'dh_installsystemd')); ok(-e "debian/foo/lib/systemd/system/foo.service"); ok(-e "debian/foo.postinst.debhelper"); @@ -131,19 +131,6 @@ each_compat_from_and_above_subtest(11, sub { unit_is_enabled('foo', 'foo2', 1); unit_is_started('foo', 'foo2', 1); ok(run_dh_tool('dh_clean')); -}); +}; -each_compat_up_to_and_incl_subtest(10, sub { - - ok(run_dh_tool({ 'needs_root' => 1 }, 'dh_installsystemd')); - ok(! -e "debian/foo/lib/systemd/system/foo.service"); - ok(! -e "debian/foo.postinst.debhelper"); - ok(run_dh_tool('dh_clean')); - - make_path(qw(debian/foo/lib/systemd/system/)); - install_file('debian/foo.service', 'debian/foo/lib/systemd/system/foo.service'); - ok(run_dh_tool({ 'needs_root' => 1 }, 'dh_installsystemd')); - ok(! -e "debian/foo.postinst.debhelper"); - ok(run_dh_tool('dh_clean')); -}); -- cgit v1.2.3