[saods9] 01/01: Add CI tests

Ole Streicher olebole at moszumanska.debian.org
Mon Jun 8 14:44:00 UTC 2015


This is an automated email from the git hooks/post-receive script.

olebole pushed a commit to branch debian
in repository saods9.

commit 835d3a01b3ecb3256257d27944214765f803d95b
Author: Ole Streicher <debian at liska.ath.cx>
Date:   Mon Jun 8 16:44:54 2015 +0200

    Add CI tests
---
 debian/changelog        |  6 ++++++
 debian/tests/control    |  5 +++++
 debian/tests/saods9     | 33 +++++++++++++++++++++++++++++++++
 debian/tests/saods9-xpa | 30 ++++++++++++++++++++++++++++++
 4 files changed, 74 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index ae3564c..a828ff1 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+saods9 (7.3.2+repack-3) UNRELEASED; urgency=low
+
+  * Add CI tests (ds9 with and without XPA)
+
+ -- Ole Streicher <olebole at debian.org>  Mon, 08 Jun 2015 16:43:39 +0200
+
 saods9 (7.3.2+repack-2) unstable; urgency=low
 
   * Create upstream/metadata with bibliographic information
diff --git a/debian/tests/control b/debian/tests/control
new file mode 100644
index 0000000..6d60cdb
--- /dev/null
+++ b/debian/tests/control
@@ -0,0 +1,5 @@
+Tests: saods9
+Depends: saods9, xauth, xpa-tools, xvfb
+
+Tests: saods9-xpa
+Depends: saods9, xauth, xpa-tools, xvfb
diff --git a/debian/tests/saods9 b/debian/tests/saods9
new file mode 100755
index 0000000..40f9462
--- /dev/null
+++ b/debian/tests/saods9
@@ -0,0 +1,33 @@
+#!/bin/sh
+
+#
+# This simple test loads a small FITS image, prints it to a postscript file
+# and then quits DS9. The FITS file is create by funtools.
+#
+
+cd "${ADTTMP}"
+
+funimage stdin'[TEXT(x:I:100,y:I:100),cir(50,50,40),point(100,1),-cir(50,50,2)]' \
+    tmpfile.fits bitpix=8,mask=all < /dev/null
+
+xvfb-run --server-args="-screen 0 1024x768x24" ds9 tmpfile.fits \
+    -print destination file \
+    -print filename tmpfile.ps \
+    -print \
+    -quit
+
+res=$?
+
+ls -l
+
+if [ $res != 0 ] ; then
+    echo "Error $res executing ds9"
+    exit 1
+fi
+if [ -s tmpfile.ps ] ; then
+    echo "ds9 OK"
+    exit 0
+else
+    echo "ds9 did not create output"
+    exit 1
+fi
diff --git a/debian/tests/saods9-xpa b/debian/tests/saods9-xpa
new file mode 100755
index 0000000..d342d03
--- /dev/null
+++ b/debian/tests/saods9-xpa
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+#
+# This simple test loads a small FITS image, prints it to a postscript file
+# and then quits DS9. The FITS file is create by funtools.
+#
+
+cd "${ADTTMP}"
+
+funimage stdin'[TEXT(x:I:100,y:I:100),cir(50,50,40),point(100,1),-cir(50,50,2)]' \
+    tmpfile.fits bitpix=8,mask=all < /dev/null
+
+xvfb-run --server-args="-screen 0 1024x768x24" ds9 &
+ppid=$!
+sleep 1
+
+echo "print destination file" | xpaset ds9
+echo "print filename tmpfile.ps" | xpaset ds9
+echo "print" | xpaset ds9
+echo "quit" | xpaset ds9
+ 
+ls -l
+
+if [ -s tmpfile.ps ] ; then
+    echo "ds9 OK"
+    exit 0
+else
+    echo "ds9 did not create output"
+    exit 1
+fi

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-astro/packages/saods9.git



More information about the debian-science-commits mailing list