pytest-html-reporter icon indicating copy to clipboard operation
pytest-html-reporter copied to clipboard

Rerun count doesn't increase, it still count in FAILED

Open SimonChou-17LIVE opened this issue 2 years ago • 0 comments

Hello @prashanth-sams

Firstly, thanks for you to develop such a wonderful automation reporting, it's amazing.

But I meet a situation, when I run my pytest script, the fail item will rerun, but the rerun count doesn't increase. Conversely, increasing the number of failures

I am use pytest-rerunfailures tools, and add the code "@pytest.mark.flaky(reruns=5, reruns_delay=2)" on test function My test code like as below

test_addreprot.py

import pytest, unittest

class MainTest(unittest.TestCase):

    @pytest.mark.flaky(reruns=5, reruns_delay=2)
    def test_001(self):
        assert 1 == 2


if __name__ == "__main__":
    cmd = ["-v", "-s"]  # debug on local
    cmd.append("--html-report=report.html")

    pytest.main(cmd)

excute method: python3 test_addreprot.py

SimonChou-17LIVE avatar Apr 07 '22 07:04 SimonChou-17LIVE