X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/9fb7687e6703fa66ed14f98fe212c6c3b6d8b101..62ed8312acadacf25189ce5d5da0f37c016739dd:/sdk/cwl/tests/matcher.py diff --git a/sdk/cwl/tests/matcher.py b/sdk/cwl/tests/matcher.py index d3c93168e1..892586247c 100644 --- a/sdk/cwl/tests/matcher.py +++ b/sdk/cwl/tests/matcher.py @@ -1,5 +1,6 @@ import difflib import json +import re class JsonDiffMatcher(object): @@ -21,3 +22,7 @@ class JsonDiffMatcher(object): actual_json.splitlines(1), fromfile="Expected", tofile="Actual"))) return True + + +def StripYAMLComments(yml): + return re.sub(r'(?ms)^(#.*?\n)*\n*', '', yml)