Generate single HTML file from allure report.
Low maintenance activity. Last release over 3 years ago, commits in 0 of the last 26 weeks. Weaker on commit activity and recent releases.
$
pip install allure-combineAllure single html file builder
Tool to build allure generated folder into a single html file
What it's doing?
After run by console command, or by call from python code, it:
- Reads contents of allure-generated folder
- Creates server.js file, which has all the data files inside and code to start fake XHR server
- Patches index.html file, so it's using server.js and sinon-9.2.4.js (Taken from here), and could be run in any browser without --allow-file-access-from-files parameter of chrome browser
- Creates file complete.html with all files built-in in a single file
Requirements
- Python 3.6+
- You need to have your allure report folder generated (
allure generate './some/path/to/allure/generated/folder')
Installation
Install with pip
pip install allure-combine
or:
Install manually
- Clone repo
git clone git@github.com:MihanEntalpo/allure-single-html-file.git
cd allure-single-html-file
- Install requirements (actually there are only BeautifulSoup)
pip install -r ./requirements.txt
python setup.py install
Run as console script
If you have cloned repo, not installed module via pip, replace allure-combine with python ./allure_combine/combine.py in following commands:
- Create complete.html file inside the allure folder itself
allure-combine ./some/path/to/allure/generated/folder
- Create complete.html file inside specified folder:
allure-combine ./some/path/to/allure/generated/folder --dest /tmp
- Ensure that specified dest folder exists (create if not)
allure-combine ./some/path/to/allure/generated/folder --dest /tmp/allure-2022-05-05_12-20-01/result --auto-create-folders
- Remove sinon.js and server.js from allure folder after complete.html is generated:
allure-combine ./some/path/to/allure/generated/folder --remove-temp-files
- If html/json files what should be utf-8 is has broken encoding, ignore errors: