Can't use allure report with pytest under mac
See original GitHub issueHi, I’m having trouble with allure reports using pytest. It seems allure command is recognized but somehow when I add it in the pytest command as a parameter it causes an error and exits. Maybe I’m missing something, here’s command line:
pytest.main("--maxfail=50 /Users/distiller/project/tests --alluredir=/Users/distiller/project/tests/build/reports")
If I use --junitxml
instead it works.
I’m triggering tests under a remote Mac using CircleCi tool. Here’s mac build configuration:
version: 2
jobs:
build:
macos:
xcode: "10.1.0"
steps:
- checkout
- run:
halt_build_on_fail: false
name: Setup environment for test
command: |
xcodebuild -version
pip install -U selenium
pip install --upgrade pip
pip install -U webium
pip install pytest
pip install -U pytest-allure-adaptor
pip install pytest-html
pip install pyperclip==1.5.27
pip install seleniumwrapper
pip install pycrypto
pip install requests
pip install -U py2app
brew install pigz
python -c "import selenium; print(selenium.__version__)"
brew install allure
sudo /usr/bin/safaridriver --enable
- run:
name: Make Unit Test
command: |
cd tools && chmod a+x tests_runner.py
py2applet --make-setup tests_runner.py
python setup.py py2app -A
open -a /Users/distiller/project/tools/dist/tests_runner.app
testrunner=$(eval "ps -ef | grep -v "grep" | grep 'tests_runner' | wc -l")
while [ "$testrunner" != 0 ]
do
testrunner=$(eval "ps -ef | grep -v "grep" | grep 'tests_runner' | wc -l")
echo "running tests.."
sleep 5
done
no_output_timeout: 20m
- run:
name: Allure Generate
when: always
command: |
allure generate -o /Users/distiller/project/tests/build/reports/ /Users/distiller/project/tests/build/reports/
mv /Users/distiller/project/tests/build/reports/ /tmp/app
- store_artifacts:
path: /tmp/app
I’m using:
- Pytest: 4.6.4
- Allure version: 2.12.1
- pytest-allure-adaptor: 1.7.10
- Selenium: 3.141
Attaching console log I got after attempting test run with allure: console remote error.txt
I’d appreciate if you can help me with this, I’m pretty sure I’m missing some configuration detail…
Thanks in advance!
Regards,
Ashley
Issue Analytics
- State:
- Created 4 years ago
- Comments:20 (11 by maintainers)
Top Results From Across the Web
Generating allure report using pytest - python - Stack Overflow
I am using py test allure adaptor and trying to generate input data required for allure report. But I am not able to...
Read more >How To Fix - Mac, PyTest, Python, Report By QA COACH
bash: allure : command not foundOpen URL - https://docs.qameta.io/ allure /Download the latest version as zip archive from Maven CentralUnzip ...
Read more >How To Generate Allure Reports in Selenium with Python ...
Your browser can't play this video. Learn more. Switch camera.
Read more >allure quick demo with pytest - YouTube
A quick guide on how to use allure test reporting framework with pytest.Will be posting more videos, ... Your browser can't play this...
Read more >Allure Framework
Allure Framework is a flexible lightweight multi-language test report tool that not only shows a very concise representation of what have ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
You are welcome!
Closing this issue, I solved it following documentation in https://docs.qameta.io/allure for Windows doing manual installation and for Mac remote just using libraries detailed in doc. Thanks support guys for quick and efficient responses!