Skip to content

Instantly share code, notes, and snippets.

@agamm
Last active September 17, 2020 19:16
Show Gist options
  • Save agamm/ed59391fc449e957b44636c13491ac3c to your computer and use it in GitHub Desktop.
Save agamm/ed59391fc449e957b44636c13491ac3c to your computer and use it in GitHub Desktop.

If you have many files of go test runs concat like so: cat <path>/* > concat_tests.raw

Call: python t.py concat_tests.raw

import sys
import re
with open(sys.argv[1], 'r') as f:
data = f.read()
passes = re.findall(r'(?<=PASS:\s).*?(?=\s\()', data)
passes.sort()
print("\n".join(passes))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment