[med-svn] [Git][med-team/seqan-raptor][master] d/tests/*: added post-install CLI tests againsted the installed binary.

Michael R. Crusoe (@crusoe) gitlab at salsa.debian.org
Fri Aug 25 13:01:36 BST 2023



Michael R. Crusoe pushed to branch master at Debian Med / seqan-raptor


Commits:
ccc417f8 by Michael R. Crusoe at 2023-08-25T14:00:32+02:00
d/tests/*: added post-install CLI tests againsted the installed binary.

- - - - -


5 changed files:

- debian/changelog
- debian/rules
- debian/tests/control
- debian/tests/run-unit-test
- + debian/tests/use_installed_binaries.patch


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,10 @@
+seqan-raptor (3.0.1+ds-4) UNRELEASED; urgency=medium
+
+  * d/tests/*: added post-install running of the CLI tests againsted the
+    installed binary.
+
+ -- Michael R. Crusoe <crusoe at debian.org>  Fri, 25 Aug 2023 13:59:55 +0200
+
 seqan-raptor (3.0.1+ds-3) unstable; urgency=medium
 
   * d/rules,d/tests/*: whoops, more work needed to build & run all the available


=====================================
debian/rules
=====================================
@@ -3,7 +3,7 @@
 # DH_VERBOSE := 1
 export LC_ALL=C.UTF-8
 export DEB_BUILD_MAINT_OPTIONS=hardening=+all
-export DEB_CPPFLAGS_MAINT_APPEND=-I/usr/include/seqan3/submodules/sdsl-lite/include/ -I/usr/include/simde -I${CURDIR}/lib/submodules/sharg-parser/include/ -I${CURDIR}/lib/submodules/lemon/include/
+export DEB_CPPFLAGS_MAINT_APPEND=-I/usr/include/seqan3/submodules/sdsl-lite/include/ -I/usr/include/simde -I${CURDIR}/lib/sharg-parser/include/ -I${CURDIR}/lib/submodules/lemon/include/
 export DEB_CFLAGS_MAINT_APPEND=-O3
 export DEB_CXXFLAGS_MAINT_APPEND=-O3
 DPKG_EXPORT_BUILDFLAGS = 1


=====================================
debian/tests/control
=====================================
@@ -2,6 +2,6 @@ Tests: cwl
 Depends: @, cwltool, python3-setuptools, nodejs
 Restrictions: allow-stderr
 
-# Tests: run-unit-test
-# Depends: @, cmake
-# Restrictions: allow-stderr
+Tests: run-unit-test
+Depends: @, cmake, g++, patch, libseqan3-dev, libyaml-cpp-dev, libxxhash-dev, pkg-config, libgtest-dev, libsimde-dev
+Restrictions: allow-stderr


=====================================
debian/tests/run-unit-test
=====================================
@@ -1,5 +1,5 @@
 #!/bin/bash
-set -e
+set -ex
 
 pkg=seqan-raptor
 
@@ -10,10 +10,14 @@ if [ "${AUTOPKGTEST_TMP}" = "" ] ; then
   trap "rm -rf ${AUTOPKGTEST_TMP}" 0 INT QUIT ABRT PIPE TERM
 fi
 
-cp -r test "${AUTOPKGTEST_TMP}"
+cp -r * "${AUTOPKGTEST_TMP}"
+export CXXFLAGS="-I/usr/include/seqan3/submodules/sdsl-lite/include/ -I/usr/include/simde -I${AUTOPKGTEST_TMP}/lib/sharg-parser/include/ -I${AUTOPKGTEST_TMP}/lib/submodules/lemon/include/"
 
-# Build some data for the test binaries as prerequisites
+cd "${AUTOPKGTEST_TMP}"
+patch -p1 < debian/tests/use_installed_binaries.patch
 cd "${AUTOPKGTEST_TMP}"/test/unit
-cmake .
-make CMAKE_BINARY_DIR=/usr
+cmake -DRAPTOR_SUBMODULES_DIR=${PWD}/../../lib .
+make
+find . -name raptor -delete
 ctest .
+find . -name raptor


=====================================
debian/tests/use_installed_binaries.patch
=====================================
@@ -0,0 +1,24 @@
+From 16574d230f0e4cf45b1b1b9f8d5e2de41d2411a2 Mon Sep 17 00:00:00 2001
+From: Enrico Seiler <enrico.seiler at hotmail.de>
+Date: Mon, 21 Aug 2023 16:11:32 +0200
+Subject: [PATCH] Use /usr/bin/raptor for tests
+
+---
+ test/raptor-test.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/test/raptor-test.cmake b/test/raptor-test.cmake
+index 7275ffe..3ea6210 100644
+--- a/test/raptor-test.cmake
++++ b/test/raptor-test.cmake
+@@ -123,4 +123,4 @@ endif ()
+ file (MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/output)
+ add_definitions (-DOUTPUTDIR=\"${CMAKE_CURRENT_BINARY_DIR}/output/\")
+ add_definitions (-DDATADIR=\"${CMAKE_CURRENT_BINARY_DIR}/data/\")
+-add_definitions (-DBINDIR=\"${CMAKE_BINARY_DIR}/bin/\")
++add_definitions (-DBINDIR=\"/usr/bin/\")
+-- 
+2.41.0
+
+
+



View it on GitLab: https://salsa.debian.org/med-team/seqan-raptor/-/commit/ccc417f85caa72d7a426bb744fba16fea396b1ec

-- 
View it on GitLab: https://salsa.debian.org/med-team/seqan-raptor/-/commit/ccc417f85caa72d7a426bb744fba16fea396b1ec
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20230825/2f8534c7/attachment-0001.htm>


More information about the debian-med-commit mailing list