Mercurial > repos > blastem
comparison maketests.py @ 214:9126c33cc33c
Add test generator, builder and runner
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Fri, 19 Apr 2013 09:29:37 -0700 |
parents | |
children | f7ff02eeec2f |
comparison
equal
deleted
inserted
replaced
213:4d4559b04c59 | 214:9126c33cc33c |
---|---|
1 #!/usr/bin/env python | |
2 from glob import glob | |
3 import subprocess | |
4 from sys import exit | |
5 | |
6 sources = set() | |
7 for path in glob('generated_tests/*.s68'): | |
8 sources.add(path) | |
9 | |
10 bins = set() | |
11 for path in glob('generated_tests/*.bin'): | |
12 bins.add(path) | |
13 | |
14 for path in sources: | |
15 binpath = path.replace('.s68', '.bin') | |
16 if not binpath in bins: | |
17 print binpath | |
18 res = subprocess.call(['vasmm68k_mot', '-Fbin', '-m68000', '-no-opt', '-spaces', '-o', binpath, path]) | |
19 if res != 0: | |
20 print 'vasmm68k_mot returned non-zero status code', res | |
21 exit(1) | |
22 |