summaryrefslogtreecommitdiffstats
path: root/tests/t-triggers-cycle/Makefile
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 09:40:31 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 09:40:31 +0000
commitb86570f63e533abcbcb97c2572e0e5732a96307b (patch)
treecabc83be691530ae685c45a8bc7620ccc0e1ebdf /tests/t-triggers-cycle/Makefile
parentInitial commit. (diff)
downloaddpkg-b86570f63e533abcbcb97c2572e0e5732a96307b.tar.xz
dpkg-b86570f63e533abcbcb97c2572e0e5732a96307b.zip
Adding upstream version 1.20.13.upstream/1.20.13upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/t-triggers-cycle/Makefile')
-rw-r--r--tests/t-triggers-cycle/Makefile21
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/t-triggers-cycle/Makefile b/tests/t-triggers-cycle/Makefile
new file mode 100644
index 0000000..b17f877
--- /dev/null
+++ b/tests/t-triggers-cycle/Makefile
@@ -0,0 +1,21 @@
+TESTS_DEB := pkg-depends pkg-trigger-a pkg-trigger-b
+
+include ../Test.mk
+
+test-case:
+ $(DPKG_INSTALL) pkg-depends.deb
+ # Should fail due to a trigger cycle.
+ ! $(DPKG_INSTALL) pkg-trigger-a.deb pkg-trigger-b.deb
+ ! $(DPKG_CONFIGURE) --pending
+
+ # Make sure everything is left in a correct state.
+ $(call pkg_is_installed,pkg-depends)
+ $(call pkg_is_installed,pkg-trigger-a)
+ $(call pkg_status_is,pkg-trigger-b,install ok half-configured)
+
+ # Cleanup.
+ $(DPKG_PURGE) pkg-trigger-a pkg-trigger-b
+ $(DPKG_PURGE) pkg-depends
+
+test-clean:
+ -$(DPKG_PURGE) pkg-trigger-a pkg-trigger-b pkg-depends