aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2021-04-01 14:42:07 -0700
committerSean Whitton <spwhitton@spwhitton.name>2021-04-01 15:56:45 -0700
commit0fef94b5318fa4831a773f34e3994be9258d1f78 (patch)
treee6f24184bd907f6e127d06d543853329dd0a4cb7
parent9d7f1a796750947a185a1251b89b8570fc51f2d5 (diff)
downloadconsfigurator-0fef94b5318fa4831a773f34e3994be9258d1f78.tar.gz
debian/: run upstream test suite as part of autopkgtest
Signed-off-by: Sean Whitton <spwhitton@spwhitton.name>
-rw-r--r--debian/changelog1
-rw-r--r--debian/install2
-rw-r--r--debian/tests/compile-and-tests.lisp13
-rw-r--r--debian/tests/compile.lisp9
-rw-r--r--debian/tests/control2
5 files changed, 16 insertions, 11 deletions
diff --git a/debian/changelog b/debian/changelog
index 37839f0..3d73d76 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,7 @@ consfigurator (0.4.0-1) UNRELEASED; urgency=medium
* Add deps and build-deps on cl-heredoc, cl-named-readtables,
cl-trivial-backtrace.
+ * Run upstream test suite as part of autopkgtest.
-- Sean Whitton <spwhitton@spwhitton.name> Sat, 20 Mar 2021 12:31:53 -0700
diff --git a/debian/install b/debian/install
index 3a0b75e..7b653d5 100644
--- a/debian/install
+++ b/debian/install
@@ -1 +1 @@
-consfigurator.asd src usr/share/common-lisp/source/consfigurator/
+consfigurator.asd src tests usr/share/common-lisp/source/consfigurator/
diff --git a/debian/tests/compile-and-tests.lisp b/debian/tests/compile-and-tests.lisp
new file mode 100644
index 0000000..568fd72
--- /dev/null
+++ b/debian/tests/compile-and-tests.lisp
@@ -0,0 +1,13 @@
+(require "asdf")
+
+;; this in itself ensures that we've listed the files in consfigurator.asd in
+;; the correct order
+(let ((asdf:*compile-file-failure-behaviour* :error)
+ (asdf:*compile-file-warnings-behaviour* :error)
+ (asdf:*user-cache* (uiop:getenv "AUTOPKGTEST_TMP")))
+ (asdf:load-system "consfigurator/tests"))
+
+;; we can't use ASDF:TEST-SYSTEM because its return value does not indicate
+;; whether any tests failed
+(unless (consfigurator/tests::do-tests)
+ (uiop:quit 2))
diff --git a/debian/tests/compile.lisp b/debian/tests/compile.lisp
deleted file mode 100644
index b4377ba..0000000
--- a/debian/tests/compile.lisp
+++ /dev/null
@@ -1,9 +0,0 @@
-(require "asdf")
-
-;; this ensures that we've listed the files in consfigurator.asd in the
-;; correct order
-
-(let ((asdf:*compile-file-failure-behaviour* :error)
- (asdf:*compile-file-warnings-behaviour* :error)
- (asdf:*user-cache* (uiop:getenv "AUTOPKGTEST_TMP")))
- (asdf:load-system "consfigurator"))
diff --git a/debian/tests/control b/debian/tests/control
index a52a8f5..4d13430 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -1,4 +1,4 @@
-Test-Command: sbcl --script debian/tests/compile.lisp
+Test-Command: sbcl --script debian/tests/compile-and-tests.lisp
Depends:
sbcl,
@,