I am getting unrecognized argument error while generating .html allure report using following command:
pytest -s --html=C:/Git_Data/automationFrameworks/SelFinal/allureReport/report.html test_a.py
Error in output:
ERROR: usage: pytest [options] [file_or_dir] [file_or_dir] [...] pytest: error: unrecognized arguments: --html=C:/Git_Data/automationFrameworks/SelFinal/allureReport/report.html inifile: None rootdir: C:\Git_Data\automationFrameworks\SelFinal\projectStructure\testcases
Attached files for Envrionment variable, desktop path for allure report and cmd
Environment variable screenshot
Desktop Path screenshot
InstructorJaspreet Replied on 27/01/2021
You need to have a package in your system to generate the HTML reports directly. The package to be installed is "pytest-html". Use command "pip install pytest-html" on the command prompt. It needs not be set anywhere just install the oackage and run your command to generate HTML report.
Thanks, it works as expected now.
Please close the ticket.
InstructorJaspreet Replied on 01/02/2021
Thank you for update.