test cache: use .bin extension, fix .gitignore .gitattributes

This commit is contained in:
James R. Barlow 2018-03-24 23:54:16 -07:00
parent 961c1365f9
commit 77476965ae
3 changed files with 4 additions and 4 deletions

2
.gitattributes vendored
View File

@ -8,6 +8,6 @@
*.PDF binary
*.png binary
*.jpg binary
*.bin binary
.git_archival.txt export-subst

1
.gitignore vendored
View File

@ -35,7 +35,6 @@ log/
/*.qdf
*.ipynb
.ipynb_checkpoints/
tests/cache/
tests/output/
tests/resources/private/
tmp/

View File

@ -136,7 +136,8 @@ def main():
for configfile in args.configfiles:
# cp cache -> output
tessfile = args.outputbase + '.' + configfile
shutil.copy(str(cache_folder / configfile), tessfile)
shutil.copy(str(cache_folder / configfile + '.bin'),
tessfile)
sys.exit(0)
# Cache miss
@ -166,7 +167,7 @@ def main():
continue
# cp pwd/{outputbase}.{configfile} -> {cache}/{configfile}
tessfile = args.outputbase + '.' + configfile
shutil.copy(tessfile, str(cache_folder / configfile))
shutil.copy(tessfile, str(cache_folder / configfile + '.bin'))
(cache_folder / 'stderr').write_bytes(p.stderr)