[med-svn] [Git][med-team/cwltool][master] 2 commits: speed up autopkgtesting

Michael R. Crusoe gitlab at salsa.debian.org
Mon Dec 24 19:52:17 GMT 2018


Michael R. Crusoe pushed to branch master at Debian Med / cwltool


Commits:
26ea60b7 by Michael R. Crusoe at 2018-12-24T19:09:57Z
speed up autopkgtesting

- - - - -
7f42ec5b by Michael R. Crusoe at 2018-12-24T19:51:18Z
fix the packing test

- - - - -


5 changed files:

- debian/changelog
- debian/patches/add-exec-line
- debian/rules
- debian/tests/control
- debian/tests/run-tests


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,9 @@
+cwltool (1.0.20181217162649+dfsg-3) unstable; urgency=medium
+
+  * Fix our patches to the tests, run them in parallel
+
+ -- Michael R. Crusoe <michael.crusoe at gmail.com>  Mon, 24 Dec 2018 11:51:11 -0800
+
 cwltool (1.0.20181217162649+dfsg-2) unstable; urgency=medium
 
   * debian/tests/control: fix typo in name of py.test-3


=====================================
debian/patches/add-exec-line
=====================================
@@ -218,3 +218,27 @@ Forwarded: https://github.com/common-workflow-language/cwltool/pull/1023
 -      print(time.time())
 \ No newline at end of file
 +      print(time.time())
+--- cwltool.orig/tests/test_pack.py
++++ cwltool/tests/test_pack.py
+@@ -1,10 +1,11 @@
+-import json
+ import os
+ import tempfile
+ from functools import partial
+ 
+ from six import StringIO
+ import pytest
++import json
++from ruamel import yaml
+ 
+ import cwltool.pack
+ import cwltool.workflow
+@@ -25,7 +26,7 @@
+         document_loader, workflowobj, uri, [], {})
+ 
+     with open(get_data("tests/wf/expect_packed.cwl")) as packed_file:
+-        expect_packed = json.load(packed_file)
++        expect_packed = yaml.load(packed_file)
+ 
+     packed = cwltool.pack.pack(document_loader, processobj, uri, metadata)
+     adjustFileObjs(packed, partial(make_relative, os.path.abspath(get_data("tests/wf"))))


=====================================
debian/rules
=====================================
@@ -30,6 +30,6 @@ ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
 	PYBUILD_TEST_ARGS="cd {dir}; export PATH={destdir}/usr/bin:$$PATH ; \
 	cd {build_dir}; export PYTHONPATH=$$(pwd); python3 -m pytest \
 		-k 'not test_http_path_mapping and not test_pack and not test_get_subgraph and not TestUdocker' \
-		-n auto --ignore cwltool/schemas/ --pyarg cwltool" dh_auto_test
+		-n auto --dist=loadfile --ignore cwltool/schemas/ --pyarg cwltool" dh_auto_test
 endif
 


=====================================
debian/tests/control
=====================================
@@ -1,3 +1,3 @@
 Tests: run-tests
-Depends: @, python3-pytest, python3-mock, python3-pytest-runner, nodejs, singularity-container, docker.io
+Depends: @, python3-pytest-xdist, python3-mock, python3-pytest-runner, nodejs, singularity-container, docker.io
 Restrictions: allow-stderr


=====================================
debian/tests/run-tests
=====================================
@@ -5,4 +5,5 @@ if [ "$ADTTMP" = "" ] ; then
 	ADTTMP=$(mktemp -d /tmp/${pkg}-test.XXXXXX)
 fi
 cd "$ADTTMP"
-py.test-3 --ignore cwltool/schemas --pyarg cwltool
+py.test-3 --numprocesses=auto --dist=loadfile --ignore cwltool/schemas \
+	--pyarg cwltool



View it on GitLab: https://salsa.debian.org/med-team/cwltool/compare/2cb6089753229f26aaf3abc4d8e21150bd6a58ee...7f42ec5b24a6371afa78229d4dd9578edf534a5d

-- 
View it on GitLab: https://salsa.debian.org/med-team/cwltool/compare/2cb6089753229f26aaf3abc4d8e21150bd6a58ee...7f42ec5b24a6371afa78229d4dd9578edf534a5d
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/20181224/071a9e93/attachment-0001.html>


More information about the debian-med-commit mailing list