Generate single HTML file from allure report.
Tool to build allure generated folder into a single html file
After run by console command, or by call from python code, it:
allure generate './some/path/to/allure/generated/folder'
)pip install allure-combine
or:
git clone git@github.com:MihanEntalpo/allure-single-html-file.git
cd allure-single-html-file
pip install -r ./requirements.txt
python setup.py install
If you have cloned repo, not installed module via pip, replace allure-combine
with python ./allure_combine/combine.py
in following commands:
allure-combine ./some/path/to/allure/generated/folder
allure-combine ./some/path/to/allure/generated/folder --dest /tmp
allure-combine ./some/path/to/allure/generated/folder --dest /tmp/allure-2022-05-05_12-20-01/result --auto-create-folders
allure-combine ./some/path/to/allure/generated/folder --remove-temp-files
allure-combine ./some/path/to/allure/generated/folder --ignore-utf8-errors
pip install allure-combine
from allure_combine import combine_allure
# 1) Create complete.html in allure-generated folder
combine_allure("./some/path/to/allure/generated/folder")
# 2) Create complete.html in specified folder
combine_allure("./some/path/to/allure/generated/folder", dest_folder="/tmp")
# 3) Make sure that dest folder exists, create if not
combine_allure(
"./some/path/to/allure/generated/folder",
dest_folder="/tmp/allure-2022-05-05_12-20-01/result",
auto_create_folders=True
)
# 4) Remove sinon.js and server.js from allure folder after complete.html is generated:
combine_allure(
"./some/path/to/allure/generated/folder",
remove_temp_files=True
)
# 5) If html/json files what should be utf-8 is has broken encoding, ignore errors:
combine_allure(
"./some/path/to/allure/generated/folder",
ignore_utf8_errors=True
)