Skip to content

Commit 6049764

Browse files
committed
expected output doesn't have to include location&path
1 parent 9db8c1d commit 6049764

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

cwltest/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,6 @@ def run_test(args, i, tests): # type: (argparse.Namespace, int, List[Dict[str,
159159

160160

161161
def main(): # type: () -> int
162-
_logger.handlers.pop() # prints log messages twice without this line
163162

164163
parser = argparse.ArgumentParser(description='Compliance tests for cwltool')
165164
parser.add_argument("--test", type=str, help="YAML file describing test cases", required=True)

cwltest/utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,10 @@ def compare_location(expected, actual):
2323
comp = "path"
2424
if "path" not in actual:
2525
actual["path"] = actual["location"]
26-
else:
26+
elif "location" in expected:
2727
comp = "location"
28+
else:
29+
return
2830
if expected[comp] != "Any" and (not (actual[comp].endswith("/" + expected[comp]) or
2931
("/" not in actual[comp] and expected[comp] == actual[comp]))):
3032
raise CompareFail.format(expected, actual, u"%s does not end with %s" % (actual[comp], expected[comp]))

0 commit comments

Comments
 (0)