[med-svn] [Git][med-team/kmer][master] Add autopkgtest

Liubov Chuprikova gitlab at salsa.debian.org
Mon Aug 20 09:09:49 BST 2018


Liubov Chuprikova pushed to branch master at Debian Med / kmer


Commits:
e910a4d3 by Liubov Chuprikova at 2018-08-20T08:09:09Z
Add autopkgtest

- - - - -


9 changed files:

- + debian/README.test
- debian/atac.docs
- debian/changelog
- debian/copyright
- debian/sim4db.docs
- debian/tests/atac-unit-test
- debian/tests/control
- + debian/tests/sim4db-unit-test
- debian/tests/test-data/test_data.tar.gz


Changes:

=====================================
debian/README.test
=====================================
--- /dev/null
+++ b/debian/README.test
@@ -0,0 +1,14 @@
+Notes on how the packages can be tested in order to confirm their integrity.
+____________________________________________________________________________
+
+To test atac run:
+
+	sh atac-unit-test
+
+NOTE: Atac test fails with a segmentation fault. Feel free to use `reportbug
+atac` if you have some idea how to fix the test.
+
+To test sim4db run:
+
+        sh sim4db-unit-test
+


=====================================
debian/atac.docs
=====================================
--- a/debian/atac.docs
+++ b/debian/atac.docs
@@ -1,3 +1,4 @@
 README.atac
 debian/tests/atac-unit-test
 debian/tests/test-data/test_data.tar.gz
+debian/README.test


=====================================
debian/changelog
=====================================
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+kmer (0~20150903+r2013-5) UNRELEASED; urgency=medium
+
+  * Team upload.
+  * Add autopkgtest.
+
+ -- Liubov Chuprikova <chuprikovalv at gmail.com>  Mon, 20 Aug 2018 09:46:55 +0200
+
 kmer (0~20150903+r2013-4) unstable; urgency=medium
 
   * Team upload.


=====================================
debian/copyright
=====================================
--- a/debian/copyright
+++ b/debian/copyright
@@ -36,6 +36,24 @@ Copyright:
 	2015-2016 Afif Elghraoui <afif at debian.org>
 License: GPL-2+
 
+Files: debian/tests/test-data/test_data.tar.gz
+Copyright: 1996-2018 NCBI
+License: unrestricted
+ Databases of molecular data on the NCBI Web site include such examples as
+ nucleotide sequences (GenBank), protein sequences, macromolecular
+ structures, molecular variation, gene expression, and mapping data. They
+ are designed to provide and encourage access within the scientific
+ community to sources of current and comprehensive information. Therefore,
+ NCBI itself places no restrictions on the use or distribution of the data
+ contained therein. Nor do we accept data when the submitter has requested
+ restrictions on reuse or redistribution.
+Comment:
+ The test data files contained in the archive were downloaded from NCBI RefSeq
+ and EST databases using wget and idfetch (from ncbi-tools-bin package):
+    wget ftp://ftp.ncbi.nlm.nih.gov/genomes/refseq/bacteria/Mycobacterium_tuberculosis/latest_assembly_versions/GCF_000195955.2_ASM19595v2/GCF_000195955.2_ASM19595v2_genomic.fna.gz
+    wget ftp://ftp.ncbi.nlm.nih.gov/genomes/refseq/bacteria/Mycobacterium_leprae/latest_assembly_versions/GCF_000195855.1_ASM19585v1/GCF_000195855.1_ASM19585v1_genomic.fna.gz
+    idfetch -G EST_GIs.txt -t 5 -o ESTs.fasta
+
 License: GPL-2+
  This package is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by


=====================================
debian/sim4db.docs
=====================================
--- a/debian/sim4db.docs
+++ b/debian/sim4db.docs
@@ -1 +1,4 @@
 README.sim4db
+debian/tests/sim4db-unit-test
+debian/tests/test-data/test_data.tar.gz
+debian/README.test


=====================================
debian/tests/atac-unit-test
=====================================
--- a/debian/tests/atac-unit-test
+++ b/debian/tests/atac-unit-test
@@ -7,9 +7,15 @@ if [ "$AUTOPKGTEST_TMP" = "" ]; then
     trap "rm -rf $AUTOPKGTEST_TMP" 0 INT QUIT ABRT PIPE TERM
 fi
 cd $AUTOPKGTEST_TMP
-cp -a /usr/share/doc/${pkg}/test_data.tar.gz .
+cp /usr/share/doc/${pkg}/test_data.tar.gz .
 tar -xzvf *.tar.gz; rm *.tar.gz
 
 # Run atac:
-atac -meryldir meryldir -dir results -id1 Ecoli -seq1 GCF_000195995.1_ASM19599v1_genomic.fna \
-	-id2 Sent -seq2 GCF_000005845.2_ASM584v2_genomic.fna
+atac -meryldir meryldir -dir results -id1 Lepr -seq1 GCF_000195855.1_ASM19585v1_genomic.fna \
+	-id2 Tuber -seq2 GCF_000195955.2_ASM19595v2_genomic.fna
+
+# FIXME! This test fails with the following error message:
+# >    Segmentation fault
+# >    Failed to ganerate statistics.
+
+echo "RESULTS: OK\n"


=====================================
debian/tests/control
=====================================
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -1,3 +1,6 @@
+Tests: sim4db-unit-test
+Depends: @
+
 Tests: atac-unit-test
 Depends: @
 Restrictions: allow-stderr


=====================================
debian/tests/sim4db-unit-test
=====================================
--- /dev/null
+++ b/debian/tests/sim4db-unit-test
@@ -0,0 +1,23 @@
+#!/bin/sh -e
+
+pkg="sim4db"
+
+if [ "$AUTOPKGTEST_TMP" = "" ]; then
+    AUTOPKGTEST_TMP=$(mktemp -d /tmp/${pkg}-test.XXXXXX)
+    trap "rm -rf $AUTOPKGTEST_TMP" 0 INT QUIT ABRT PIPE TERM
+fi
+cd $AUTOPKGTEST_TMP
+cp /usr/share/doc/${pkg}/test_data.tar.gz .
+tar -xzvf *.tar.gz; rm *.tar.gz
+
+# Run sim4db
+echo "Testing sim4 for intra-species alignment...\n"
+sim4db -genomic GCF_000195955.2_ASM19595v2_genomic.fna -cdna ESTs.fasta \
+	-output results.sim4db
+[ -s results.sim4db ]
+echo "Testing sim4cc for inter-species alignment...\n"
+sim4db -genomic GCF_000195855.1_ASM19585v1_genomic.fna -cdna ESTs.fasta \
+	-interspecies -gff3 -output results.gff3
+[ -s results.gff3 ]
+
+echo "RESULTS: OK\n"


=====================================
debian/tests/test-data/test_data.tar.gz
=====================================
Binary files a/debian/tests/test-data/test_data.tar.gz and b/debian/tests/test-data/test_data.tar.gz differ



View it on GitLab: https://salsa.debian.org/med-team/kmer/commit/e910a4d38d52f5256e55c10dfbbc9fc10dc45250

-- 
View it on GitLab: https://salsa.debian.org/med-team/kmer/commit/e910a4d38d52f5256e55c10dfbbc9fc10dc45250
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/20180820/06e57514/attachment-0001.html>


More information about the debian-med-commit mailing list