comparison planemo/lib/python3.7/site-packages/cwltool/tests/test_rdfprint.py @ 0:d30785e31577 draft

"planemo upload commit 6eee67778febed82ddd413c3ca40b3183a3898f1"
author guerler
date Fri, 31 Jul 2020 00:18:57 -0400
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:d30785e31577
1 import os
2 import sys
3
4 from cwltool.main import main
5 from cwltool.utils import subprocess
6
7 from .util import get_data
8
9
10 def test_rdf_print():
11 assert main(['--print-rdf', get_data('tests/wf/hello_single_tool.cwl')]) == 0
12
13 def test_rdf_print_unicode():
14 """Force ASCII encoding but load UTF file with --print-rdf."""
15 try:
16 lc_all = os.environ.get("LC_ALL", None)
17 os.environ["LC_ALL"] = "C"
18
19 params = [sys.executable,
20 "-m", "cwltool", '--print-rdf',
21 get_data('tests/utf_doc_example.cwl')]
22
23 assert subprocess.check_call(params) == 0
24 finally:
25 if lc_all:
26 os.environ["LC_ALL"] = lc_all