Skip to content

Commit b590789

Browse files
committed
run tests, but skip docker test on travis
1 parent 24f40b5 commit b590789

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

.travis/py3.docker

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ RUN docker-apt-install python3-pip
33
ADD . /code
44
WORKDIR /code
55
RUN pip3 install .
6+
RUN python3 setup.py test

tests/test_docker_extract.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,17 @@
1-
from unittest import TestCase
1+
from unittest import TestCase, skipIf
22
from pathlib import Path
3+
from os import environ
34
from tempfile import TemporaryDirectory
45
from cwl_utils.docker_extract import traverse, get_image_name, save_docker_image, load_docker_image
56
import cwl_utils.parser_v1_0 as parser
67

78
HERE = Path(__file__).resolve().parent
89
TEST_CWL = HERE / "../testdata/md5sum.cwl"
10+
TRAVIS = environ.get('TRAVIS', 'false') == 'true'
911

1012

1113
class TestDockerExtract(TestCase):
14+
@skipIf(TRAVIS, reason="travis doesn't running docker in docker")
1215
def test_traverse_workflow(self):
1316
loaded = parser.load_document(str(TEST_CWL.resolve()))
1417

0 commit comments

Comments
 (0)