allure 报告 空白

image.png

按照各大论坛上命令
pytest --alluredir=<directory-with-results> --clean-alluredir
allure generate <directory-with-results> -o <directory-with-report>


(pytestdemo) F:\work\program\python\pytestdemo>pytest -s -q --alluredir report/result test_demo.py --clean-alluredir
.FF
============================================================================= FAILURES =============================================================================
____________________________________________________________________________ test_add2 _____________________________________________________________________________

    def test_add2():
>       assert add(2,3) ==6
E       assert 5 == 6
E        +  where 5 = add(2, 3)

test_demo.py:8: AssertionError
____________________________________________________________________________ test_add3 _____________________________________________________________________________

    def test_add3():
>       assert add(2, 7) == 6
E       assert 9 == 6
E        +  where 9 = add(2, 7)

test_demo.py:11: AssertionError
===================================================================== short test summary info ======================================================================
FAILED test_demo.py::test_add2 - assert 5 == 6
FAILED test_demo.py::test_add3 - assert 9 == 6
2 failed, 1 passed in 0.16s

(pytestdemo) F:\work\program\python\pytestdemo>allure generate ./report -o ./report/html --clean
Report successfully generated to .\report\html

浏览器打开就这样

请大家帮忙看看问题在哪里?

阅读 1.2k
撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进