mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-19 22:50:21 +00:00
Fix BIMTester file overwrite bug and template re-reading.
This commit is contained in:
@@ -11,7 +11,7 @@ import sys
|
|||||||
def run_tests():
|
def run_tests():
|
||||||
behave_main(['features', '--junit', '--junit-directory', 'junit/'])
|
behave_main(['features', '--junit', '--junit-directory', 'junit/'])
|
||||||
print('# All tests have finished. Generating HTML reports now.')
|
print('# All tests have finished. Generating HTML reports now.')
|
||||||
with open('features/template.html') as template:
|
if not os.path.exists('report'):
|
||||||
os.mkdir('report')
|
os.mkdir('report')
|
||||||
for file in os.listdir('junit/'):
|
for file in os.listdir('junit/'):
|
||||||
if not file.endswith('.xml'):
|
if not file.endswith('.xml'):
|
||||||
@@ -41,6 +41,7 @@ def run_tests():
|
|||||||
'total_steps': len(steps)
|
'total_steps': len(steps)
|
||||||
})
|
})
|
||||||
with open('report/{}.html'.format(file[0:-4]), 'w') as out:
|
with open('report/{}.html'.format(file[0:-4]), 'w') as out:
|
||||||
|
with open('features/template.html') as template:
|
||||||
out.write(pystache.render(template.read(), data))
|
out.write(pystache.render(template.read(), data))
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user