pytest-dev / pytest-rerunfailures

a pytest plugin that re-runs failed tests up to -n times to eliminate flakey failures
Other
388 stars 83 forks source link

9.1.1: tox test suite warnings and pytest errors #159

Closed kloczek closed 4 months ago

kloczek commented 3 years ago

Generally tox is OK but it prints one warning:

py38-pytest54 create: /home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/.tox/py38-pytest54
py38-pytest54 installdeps: pytest==5.4.*
py38-pytest54 inst: /home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/.tox/.tmp/package/1/pytest-rerunfailures-9.1.1.zip
py38-pytest54 installed: attrs==21.2.0,more-itertools==8.8.0,packaging==20.9,pluggy==0.13.1,py==1.10.0,pyparsing==2.4.7,pytest==5.4.3,pytest-rerunfailures @ file:///home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/.tox/.tmp/package/1/pytest-rerunfailures-9.1.1.zip,wcwidth==0.2.5
py38-pytest54 run-test-pre: PYTHONHASHSEED='2297803885'
py38-pytest54 run-test: commands[0] | pytest test_pytest_rerunfailures.py
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.9, pytest-5.4.3, py-1.10.0, pluggy-0.13.1
cachedir: .tox/py38-pytest54/.pytest_cache
rootdir: /home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1
plugins: rerunfailures-9.1.1
collected 48 items

test_pytest_rerunfailures.py ................................................                                                                                        [100%]

============================================================================= warnings summary =============================================================================
test_pytest_rerunfailures.py: 48 tests with warnings
  /home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/.tox/py38-pytest54/lib/python3.8/site-packages/_pytest/compat.py:333: PytestDeprecationWarning: The TerminalReporter.writer attribute is deprecated, use TerminalReporter._tw instead at your own risk.
  See https://docs.pytest.org/en/latest/deprecations.html#terminalreporter-writer for more information.
    return getattr(object, name, default)

-- Docs: https://docs.pytest.org/en/latest/warnings.html
===================================================================== 48 passed, 48 warnings in 2.25s ======================================================================

Additionally output of the pytest in build env where I have installed many pytest extensions (so some of those errors may be false positive or result of some errors in those plugins. I think that it would be good if you will have a look on below log:

+ /usr/bin/python3 -Bm pytest -ra
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 50 items

. .                                                                                                                                                                  [  2%]
test_pytest_rerunfailures.py F......FFFFFFFFFF.FsFFFFFFFFFFFFFFFF.FFF.FFFF..F                                                                                        [100%]

================================================================================= FAILURES =================================================================================
_______________________________________________________________________ test_error_when_run_with_pdb _______________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_error_when_run_with_pdb0')>

    def test_error_when_run_with_pdb(testdir):
        testdir.makepyfile("def test_pass(): pass")
        result = testdir.runpytest("--reruns", "1", "--pdb")
>       result.stderr.fnmatch_lines_random("ERROR: --reruns incompatible with --pdb")
E       Failed: line 'ERROR: --reruns incompatible with --pdb' not found in output

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:52: Failed
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_error_when_run_with_pdb0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_error_when_run_with_pdb.py .                                        [100%]

============================== 1 passed in 0.05s ===============================
_____________________________________________________________ test_rerun_fails_after_consistent_setup_failure ______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_fails_after_consistent_setup_failure0')>

    def test_rerun_fails_after_consistent_setup_failure(testdir):
        testdir.makepyfile("def test_pass(): pass")
        testdir.makeconftest(
            """
            def pytest_runtest_setup(item):
                raise Exception('Setup failure')"""
        )
        result = testdir.runpytest("--reruns", "1")
>       assert_outcomes(result, passed=0, error=1, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:141:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'errors': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_fails_after_consistent_setup_failure0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_rerun_fails_after_consistent_setup_failure.py E                     [100%]

==================================== ERRORS ====================================
_________________________ ERROR at setup of test_pass __________________________

item = <Function test_pass>

    def pytest_runtest_setup(item):
>       raise Exception('Setup failure')
E       Exception: Setup failure

conftest.py:2: Exception
=========================== short test summary info ============================
ERROR test_rerun_fails_after_consistent_setup_failure.py::test_pass - Excepti...
=============================== 1 error in 0.05s ===============================
_____________________________________________________________ test_rerun_passes_after_temporary_setup_failure ______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_passes_after_temporary_setup_failure0')>

    def test_rerun_passes_after_temporary_setup_failure(testdir):
        testdir.makepyfile("def test_pass(): pass")
        testdir.makeconftest(
            """
            def pytest_runtest_setup(item):
                {}""".format(
                temporary_failure()
            )
        )
        result = testdir.runpytest("--reruns", "1", "-r", "R")
>       assert_outcomes(result, passed=1, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:154:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:41: in assert_outcomes
    check_outcome_field(outcomes, "passed", passed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'errors': 1}, field_name = 'passed', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.passed has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_passes_after_temporary_setup_failure0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_rerun_passes_after_temporary_setup_failure.py E                     [100%]

==================================== ERRORS ====================================
_________________________ ERROR at setup of test_pass __________________________

item = <Function test_pass>

    def pytest_runtest_setup(item):

        import py
        path = py.path.local(__file__).dirpath().ensure('test.res')
        count = path.read() or 1
        if int(count) <= 1:
            path.write(int(count) + 1)
>           raise Exception('Failure: {0}'.format(count))
E           Exception: Failure: 1

conftest.py:8: Exception
=============================== 1 error in 0.05s ===============================
______________________________________________________________ test_rerun_fails_after_consistent_test_failure ______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_fails_after_consistent_test_failure0')>

    def test_rerun_fails_after_consistent_test_failure(testdir):
        testdir.makepyfile("def test_fail(): assert False")
        result = testdir.runpytest("--reruns", "1")
>       assert_outcomes(result, passed=0, failed=1, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:160:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_fails_after_consistent_test_failure0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_rerun_fails_after_consistent_test_failure.py F                      [100%]

=================================== FAILURES ===================================
__________________________________ test_fail ___________________________________

>   def test_fail(): assert False
E   assert False

test_rerun_fails_after_consistent_test_failure.py:1: AssertionError
=========================== short test summary info ============================
FAILED test_rerun_fails_after_consistent_test_failure.py::test_fail - assert ...
============================== 1 failed in 0.05s ===============================
______________________________________________________________ test_rerun_passes_after_temporary_test_failure ______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_passes_after_temporary_test_failure0')>

    def test_rerun_passes_after_temporary_test_failure(testdir):
        testdir.makepyfile(
            """
            def test_pass():
                {}""".format(
                temporary_failure()
            )
        )
        result = testdir.runpytest("--reruns", "1", "-r", "R")
>       assert_outcomes(result, passed=1, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:172:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:41: in assert_outcomes
    check_outcome_field(outcomes, "passed", passed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'passed', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.passed has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_passes_after_temporary_test_failure0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_rerun_passes_after_temporary_test_failure.py F                      [100%]

=================================== FAILURES ===================================
__________________________________ test_pass ___________________________________

    def test_pass():

        import py
        path = py.path.local(__file__).dirpath().ensure('test.res')
        count = path.read() or 1
        if int(count) <= 1:
            path.write(int(count) + 1)
>           raise Exception('Failure: {0}'.format(count))
E           Exception: Failure: 1

test_rerun_passes_after_temporary_test_failure.py:8: Exception
============================== 1 failed in 0.05s ===============================
______________________________________________________ test_rerun_passes_after_temporary_test_failure_with_flaky_mark ______________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_passes_after_temporary_test_failure_with_flaky_mark0')>

    def test_rerun_passes_after_temporary_test_failure_with_flaky_mark(testdir):
        testdir.makepyfile(
            """
            import pytest
            @pytest.mark.flaky(reruns=2)
            def test_pass():
                {}""".format(
                temporary_failure(2)
            )
        )
        result = testdir.runpytest("-r", "R")
>       assert_outcomes(result, passed=1, rerun=2)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:186:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:41: in assert_outcomes
    check_outcome_field(outcomes, "passed", passed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'errors': 1}, field_name = 'passed', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.passed has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_passes_after_temporary_test_failure_with_flaky_mark0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_rerun_passes_after_temporary_test_failure_with_flaky_mark.py E      [100%]

==================================== ERRORS ====================================
_________________________ ERROR at setup of test_pass __________________________

self = <flaky.flaky_pytest_plugin.FlakyPlugin object at 0x7f49328ce550>
item = <Function test_pass>

    def pytest_runtest_setup(self, item):
        """
        Pytest hook to modify the test before it's run.

        :param item:
            The test item.
        """
        if not self._has_flaky_attributes(item):
            if hasattr(item, 'iter_markers'):
                for marker in item.iter_markers(name='flaky'):
>                   self._make_test_flaky(item, *marker.args, **marker.kwargs)
E                   TypeError: _make_test_flaky() got an unexpected keyword argument 'reruns'

/usr/lib/python3.8/site-packages/flaky/flaky_pytest_plugin.py:244: TypeError
=============================== 1 error in 0.06s ===============================
___________________________________________________________ test_reruns_if_flaky_mark_is_called_without_options ____________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0')>

    def test_reruns_if_flaky_mark_is_called_without_options(testdir):
        testdir.makepyfile(
            """
            import pytest
            @pytest.mark.flaky()
            def test_pass():
                {}""".format(
                temporary_failure(1)
            )
        )
        result = testdir.runpytest("-r", "R")
>       assert_outcomes(result, passed=1, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:200:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'passed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_if_flaky_mark_is_called_without_options.py                   [100%]. [100%]
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!

===End Flaky Test Report===

============================== 1 passed in 0.05s ===============================
_______________________________________________________ test_reruns_if_flaky_mark_is_called_with_positional_argument _______________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0')>

    def test_reruns_if_flaky_mark_is_called_with_positional_argument(testdir):
        testdir.makepyfile(
            """
            import pytest
            @pytest.mark.flaky(2)
            def test_pass():
                {}""".format(
                temporary_failure(2)
            )
        )
        result = testdir.runpytest("-r", "R")
>       assert_outcomes(result, passed=1, rerun=2)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:214:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:41: in assert_outcomes
    check_outcome_field(outcomes, "passed", passed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'passed', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.passed has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_if_flaky_mark_is_called_with_positional_argument.py          [100%]F [100%]

=================================== FAILURES ===================================
__________________________________ test_pass ___________________________________

    @pytest.mark.flaky(2)
    def test_pass():

        import py
        path = py.path.local(__file__).dirpath().ensure('test.res')
        count = path.read() or 1
        if int(count) <= 2:
            path.write(int(count) + 1)
>           raise Exception('Failure: {0}'.format(count))
E           Exception: Failure: 2

test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10: Exception
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
============================== 1 failed in 0.06s ===============================
_____________________________________________________________ test_no_extra_test_summary_for_reruns_by_default _____________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_no_extra_test_summary_for_reruns_by_default0')>

    def test_no_extra_test_summary_for_reruns_by_default(testdir):
        testdir.makepyfile(
            """
            def test_pass():
                {}""".format(
                temporary_failure()
            )
        )
        result = testdir.runpytest("--reruns", "1")
        assert "RERUN" not in result.stdout.str()
>       assert "1 rerun" in result.stdout.str()
E       AssertionError: assert '1 rerun' in '============================= test session starts ==============================\nplatform linux -- Python 3.8.9, pyt..._by_default.py::test_pass - Excep...\n============================== 1 failed in 0.06s ==============================='
E        +  where '============================= test session starts ==============================\nplatform linux -- Python 3.8.9, pyt..._by_default.py::test_pass - Excep...\n============================== 1 failed in 0.06s ===============================' = <bound method LineMatcher.str of <_pytest.pytester.LineMatcher object at 0x7f4ac2e73df0>>()
E        +    where <bound method LineMatcher.str of <_pytest.pytester.LineMatcher object at 0x7f4ac2e73df0>> = <_pytest.pytester.LineMatcher object at 0x7f4ac2e73df0>.str
E        +      where <_pytest.pytester.LineMatcher object at 0x7f4ac2e73df0> = <RunResult ret=ExitCode.TESTS_FAILED len(stdout.lines)=42 len(stderr.lines)=0 duration=0.14s>.stdout

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:227: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_no_extra_test_summary_for_reruns_by_default0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_no_extra_test_summary_for_reruns_by_default.py F                    [100%]

=================================== FAILURES ===================================
__________________________________ test_pass ___________________________________

    def test_pass():

        import py
        path = py.path.local(__file__).dirpath().ensure('test.res')
        count = path.read() or 1
        if int(count) <= 1:
            path.write(int(count) + 1)
>           raise Exception('Failure: {0}'.format(count))
E           Exception: Failure: 1

test_no_extra_test_summary_for_reruns_by_default.py:8: Exception
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_no_extra_test_summary_for_reruns_by_default.py::test_pass - Excep...
============================== 1 failed in 0.06s ===============================
____________________________________________________________________ test_extra_test_summary_for_reruns ____________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_extra_test_summary_for_reruns0')>

    def test_extra_test_summary_for_reruns(testdir):
        testdir.makepyfile(
            """
            def test_pass():
                {}""".format(
                temporary_failure()
            )
        )
        result = testdir.runpytest("--reruns", "1", "-r", "R")
>       result.stdout.fnmatch_lines_random(["RERUN test_*:*"])
E       Failed: line 'RERUN test_*:*' not found in output

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:239: Failed
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_extra_test_summary_for_reruns0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_extra_test_summary_for_reruns.py F                                  [100%]

=================================== FAILURES ===================================
__________________________________ test_pass ___________________________________

    def test_pass():

        import py
        path = py.path.local(__file__).dirpath().ensure('test.res')
        count = path.read() or 1
        if int(count) <= 1:
            path.write(int(count) + 1)
>           raise Exception('Failure: {0}'.format(count))
E           Exception: Failure: 1

test_extra_test_summary_for_reruns.py:8: Exception
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
============================== 1 failed in 0.05s ===============================
_______________________________________________________________________________ test_verbose _______________________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_verbose0')>

    def test_verbose(testdir):
        testdir.makepyfile(
            """
            def test_pass():
                {}""".format(
                temporary_failure()
            )
        )
        result = testdir.runpytest("--reruns", "1", "-v")
>       result.stdout.fnmatch_lines_random(["test_*:* RERUN*"])
E       Failed: line 'test_*:* RERUN*' not found in output

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:252: Failed
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1 -- /usr/bin/python3
cachedir: .pytest_cache
hypothesis profile 'default' -> database=DirectoryBasedExampleDatabase('/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/.hypothesis/examples')
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_verbose0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collecting ... collected 1 item

test_verbose.py::test_pass FAILED                                        [100%]

=================================== FAILURES ===================================
__________________________________ test_pass ___________________________________

    def test_pass():

        import py
        path = py.path.local(__file__).dirpath().ensure('test.res')
        count = path.read() or 1
        if int(count) <= 1:
            path.write(int(count) + 1)
>           raise Exception('Failure: {0}'.format(count))
E           Exception: Failure: 1

test_verbose.py:8: Exception
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_verbose.py::test_pass - Exception: Failure: 1
============================== 1 failed in 0.06s ===============================
_______________________________________________________________ test_rerun_on_class_setup_error_with_reruns ________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_class_setup_error_with_reruns0')>

    def test_rerun_on_class_setup_error_with_reruns(testdir):
        testdir.makepyfile(
            """
            class TestFoo(object):
                @classmethod
                def setup_class(cls):
                    assert False

                def test_pass():
                    pass"""
        )
        result = testdir.runpytest("--reruns", "1")
>       assert_outcomes(result, passed=0, error=1, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:283:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'errors': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_class_setup_error_with_reruns0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_rerun_on_class_setup_error_with_reruns.py E                         [100%]

==================================== ERRORS ====================================
_____________________ ERROR at setup of TestFoo.test_pass ______________________

cls = <class 'test_rerun_on_class_setup_error_with_reruns.TestFoo'>

    @classmethod
    def setup_class(cls):
>       assert False
E       assert False

test_rerun_on_class_setup_error_with_reruns.py:4: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_rerun_on_class_setup_error_with_reruns.py::TestFoo::test_pass - as...
=============================== 1 error in 0.05s ===============================
________________________________________________________________________ test_reruns_with_delay[-1] ________________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay0')>, delay_time = -1

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay(testdir, delay_time):
        testdir.makepyfile(
            """
            def test_fail():
                assert False"""
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest("--reruns", "3", "--reruns-delay", str(delay_time))

        if delay_time < 0:
>           result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
E           Failed: nomatch: '*UserWarning: Delay time between re-runs cannot be < 0. Using default value: 0'
E               and: '============================= test session starts =============================='
E               and: 'platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1'
E               and: 'rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay0'
E               and: 'plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2'
E               and: 'collected 1 item'
E               and: ''
E               and: 'test_reruns_with_delay.py F                                              [100%]'
E               and: ''
E               and: '=================================== FAILURES ==================================='
E               and: '__________________________________ test_fail ___________________________________'
E               and: ''
E               and: '    def test_fail():'
E               and: '>       assert False'
E               and: 'E       assert False'
E               and: ''
E               and: 'test_reruns_with_delay.py:2: AssertionError'
E               and: '===Flaky Test Report==='
E               and: ''
E               and: 'test_pass failed (1 runs remaining out of 2).'
E               and: "\t<class 'Exception'>"
E               and: '\tFailure: 1'
E               and: '\t[<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]'
E               and: 'test_pass passed 1 out of the required 1 times. Success!'
E               and: 'test_pass failed (1 runs remaining out of 2).'
E               and: "\t<class 'Exception'>"
E               and: '\tFailure: 1'
E               and: '\t[<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]'
E               and: 'test_pass failed; it passed 0 out of the required 1 times.'
E               and: "\t<class 'Exception'>"
E               and: '\tFailure: 2'
E               and: '\t[<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]'
E               and: ''
E               and: '===End Flaky Test Report==='
E               and: '=========================== short test summary info ============================'
E               and: 'FAILED test_reruns_with_delay.py::test_fail - assert False'
E               and: '============================== 1 failed in 0.05s ==============================='
E           remains unmatched: '*UserWarning: Delay time between re-runs cannot be < 0. Using default value: 0'

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:312: Failed
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay.py F                                              [100%]

=================================== FAILURES ===================================
__________________________________ test_fail ___________________________________

    def test_fail():
>       assert False
E       assert False

test_reruns_with_delay.py:2: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_reruns_with_delay.py::test_fail - assert False
============================== 1 failed in 0.05s ===============================
________________________________________________________________________ test_reruns_with_delay[0] _________________________________________________________________________

__wrapped_mock_method__ = <function NonCallableMock.assert_called_with at 0x7f493298b4c0>, args = (<MagicMock id='139959070188448'>, 0), kwargs = {}
__tracebackhide__ = True, msg = 'expected call not found.\nExpected: mock(0)\nActual: not called.', __mock_self = <MagicMock id='139959070188448'>

    def assert_wrapper(
        __wrapped_mock_method__: Callable[..., Any], *args: Any, **kwargs: Any
    ) -> None:
        __tracebackhide__ = True
        try:
>           __wrapped_mock_method__(*args, **kwargs)

/usr/lib/python3.8/site-packages/pytest_mock/plugin.py:414:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <MagicMock id='139959070188448'>, args = (0,), kwargs = {}, expected = 'mock(0)', actual = 'not called.'
error_message = 'expected call not found.\nExpected: mock(0)\nActual: not called.'

    def assert_called_with(self, /, *args, **kwargs):
        """assert that the last call was made with the specified arguments.

        Raises an AssertionError if the args and keyword args passed in are
        different to the last call to the mock."""
        if self.call_args is None:
            expected = self._format_mock_call_signature(args, kwargs)
            actual = 'not called.'
            error_message = ('expected call not found.\nExpected: %s\nActual: %s'
                    % (expected, actual))
>           raise AssertionError(error_message)
E           AssertionError: expected call not found.
E           Expected: mock(0)
E           Actual: not called.

/usr/lib64/python3.8/unittest/mock.py:904: AssertionError

During handling of the above exception, another exception occurred:

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay1')>, delay_time = 0

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay(testdir, delay_time):
        testdir.makepyfile(
            """
            def test_fail():
                assert False"""
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest("--reruns", "3", "--reruns-delay", str(delay_time))

        if delay_time < 0:
            result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
            delay_time = 0

>       time.sleep.assert_called_with(delay_time)
E       AssertionError: expected call not found.
E       Expected: mock(0)
E       Actual: not called.

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:318: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay1
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay.py F                                              [100%]

=================================== FAILURES ===================================
__________________________________ test_fail ___________________________________

    def test_fail():
>       assert False
E       assert False

test_reruns_with_delay.py:2: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_reruns_with_delay.py::test_fail - assert False
============================== 1 failed in 0.05s ===============================
_______________________________________________________________________ test_reruns_with_delay[0.0] ________________________________________________________________________

__wrapped_mock_method__ = <function NonCallableMock.assert_called_with at 0x7f493298b4c0>, args = (<MagicMock id='139959075325840'>, 0.0), kwargs = {}
__tracebackhide__ = True, msg = 'expected call not found.\nExpected: mock(0.0)\nActual: not called.', __mock_self = <MagicMock id='139959075325840'>

    def assert_wrapper(
        __wrapped_mock_method__: Callable[..., Any], *args: Any, **kwargs: Any
    ) -> None:
        __tracebackhide__ = True
        try:
>           __wrapped_mock_method__(*args, **kwargs)

/usr/lib/python3.8/site-packages/pytest_mock/plugin.py:414:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <MagicMock id='139959075325840'>, args = (0.0,), kwargs = {}, expected = 'mock(0.0)', actual = 'not called.'
error_message = 'expected call not found.\nExpected: mock(0.0)\nActual: not called.'

    def assert_called_with(self, /, *args, **kwargs):
        """assert that the last call was made with the specified arguments.

        Raises an AssertionError if the args and keyword args passed in are
        different to the last call to the mock."""
        if self.call_args is None:
            expected = self._format_mock_call_signature(args, kwargs)
            actual = 'not called.'
            error_message = ('expected call not found.\nExpected: %s\nActual: %s'
                    % (expected, actual))
>           raise AssertionError(error_message)
E           AssertionError: expected call not found.
E           Expected: mock(0.0)
E           Actual: not called.

/usr/lib64/python3.8/unittest/mock.py:904: AssertionError

During handling of the above exception, another exception occurred:

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay2')>, delay_time = 0.0

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay(testdir, delay_time):
        testdir.makepyfile(
            """
            def test_fail():
                assert False"""
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest("--reruns", "3", "--reruns-delay", str(delay_time))

        if delay_time < 0:
            result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
            delay_time = 0

>       time.sleep.assert_called_with(delay_time)
E       AssertionError: expected call not found.
E       Expected: mock(0.0)
E       Actual: not called.

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:318: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay2
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay.py F                                              [100%]

=================================== FAILURES ===================================
__________________________________ test_fail ___________________________________

    def test_fail():
>       assert False
E       assert False

test_reruns_with_delay.py:2: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_reruns_with_delay.py::test_fail - assert False
============================== 1 failed in 0.05s ===============================
________________________________________________________________________ test_reruns_with_delay[1] _________________________________________________________________________

__wrapped_mock_method__ = <function NonCallableMock.assert_called_with at 0x7f493298b4c0>, args = (<MagicMock id='139959062456784'>, 1), kwargs = {}
__tracebackhide__ = True, msg = 'expected call not found.\nExpected: mock(1)\nActual: not called.', __mock_self = <MagicMock id='139959062456784'>

    def assert_wrapper(
        __wrapped_mock_method__: Callable[..., Any], *args: Any, **kwargs: Any
    ) -> None:
        __tracebackhide__ = True
        try:
>           __wrapped_mock_method__(*args, **kwargs)

/usr/lib/python3.8/site-packages/pytest_mock/plugin.py:414:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <MagicMock id='139959062456784'>, args = (1,), kwargs = {}, expected = 'mock(1)', actual = 'not called.'
error_message = 'expected call not found.\nExpected: mock(1)\nActual: not called.'

    def assert_called_with(self, /, *args, **kwargs):
        """assert that the last call was made with the specified arguments.

        Raises an AssertionError if the args and keyword args passed in are
        different to the last call to the mock."""
        if self.call_args is None:
            expected = self._format_mock_call_signature(args, kwargs)
            actual = 'not called.'
            error_message = ('expected call not found.\nExpected: %s\nActual: %s'
                    % (expected, actual))
>           raise AssertionError(error_message)
E           AssertionError: expected call not found.
E           Expected: mock(1)
E           Actual: not called.

/usr/lib64/python3.8/unittest/mock.py:904: AssertionError

During handling of the above exception, another exception occurred:

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay3')>, delay_time = 1

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay(testdir, delay_time):
        testdir.makepyfile(
            """
            def test_fail():
                assert False"""
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest("--reruns", "3", "--reruns-delay", str(delay_time))

        if delay_time < 0:
            result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
            delay_time = 0

>       time.sleep.assert_called_with(delay_time)
E       AssertionError: expected call not found.
E       Expected: mock(1)
E       Actual: not called.

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:318: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay3
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay.py F                                              [100%]

=================================== FAILURES ===================================
__________________________________ test_fail ___________________________________

    def test_fail():
>       assert False
E       assert False

test_reruns_with_delay.py:2: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_reruns_with_delay.py::test_fail - assert False
============================== 1 failed in 0.05s ===============================
_______________________________________________________________________ test_reruns_with_delay[2.5] ________________________________________________________________________

__wrapped_mock_method__ = <function NonCallableMock.assert_called_with at 0x7f493298b4c0>, args = (<MagicMock id='139959059863920'>, 2.5), kwargs = {}
__tracebackhide__ = True, msg = 'expected call not found.\nExpected: mock(2.5)\nActual: not called.', __mock_self = <MagicMock id='139959059863920'>

    def assert_wrapper(
        __wrapped_mock_method__: Callable[..., Any], *args: Any, **kwargs: Any
    ) -> None:
        __tracebackhide__ = True
        try:
>           __wrapped_mock_method__(*args, **kwargs)

/usr/lib/python3.8/site-packages/pytest_mock/plugin.py:414:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <MagicMock id='139959059863920'>, args = (2.5,), kwargs = {}, expected = 'mock(2.5)', actual = 'not called.'
error_message = 'expected call not found.\nExpected: mock(2.5)\nActual: not called.'

    def assert_called_with(self, /, *args, **kwargs):
        """assert that the last call was made with the specified arguments.

        Raises an AssertionError if the args and keyword args passed in are
        different to the last call to the mock."""
        if self.call_args is None:
            expected = self._format_mock_call_signature(args, kwargs)
            actual = 'not called.'
            error_message = ('expected call not found.\nExpected: %s\nActual: %s'
                    % (expected, actual))
>           raise AssertionError(error_message)
E           AssertionError: expected call not found.
E           Expected: mock(2.5)
E           Actual: not called.

/usr/lib64/python3.8/unittest/mock.py:904: AssertionError

During handling of the above exception, another exception occurred:

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay4')>, delay_time = 2.5

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay(testdir, delay_time):
        testdir.makepyfile(
            """
            def test_fail():
                assert False"""
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest("--reruns", "3", "--reruns-delay", str(delay_time))

        if delay_time < 0:
            result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
            delay_time = 0

>       time.sleep.assert_called_with(delay_time)
E       AssertionError: expected call not found.
E       Expected: mock(2.5)
E       Actual: not called.

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:318: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay4
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay.py F                                              [100%]

=================================== FAILURES ===================================
__________________________________ test_fail ___________________________________

    def test_fail():
>       assert False
E       assert False

test_reruns_with_delay.py:2: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_reruns_with_delay.py::test_fail - assert False
============================== 1 failed in 0.05s ===============================
____________________________________________________________________ test_reruns_with_delay_marker[-1] _____________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker0')>, delay_time = -1

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay_marker(testdir, delay_time):
        testdir.makepyfile(
            """
            import pytest

            @pytest.mark.flaky(reruns=2, reruns_delay={})
            def test_fail_two():
                assert False""".format(
                delay_time
            )
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest()

        if delay_time < 0:
>           result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
E           Failed: nomatch: '*UserWarning: Delay time between re-runs cannot be < 0. Using default value: 0'
E               and: '============================= test session starts =============================='
E               and: 'platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1'
E               and: 'rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker0'
E               and: 'plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2'
E               and: 'collected 1 item'
E               and: ''
E               and: 'test_reruns_with_delay_marker.py E                                       [100%]'
E               and: ''
E               and: '==================================== ERRORS ===================================='
E               and: '_______________________ ERROR at setup of test_fail_two ________________________'
E               and: ''
E               and: 'self = <flaky.flaky_pytest_plugin.FlakyPlugin object at 0x7f49328ce550>'
E               and: 'item = <Function test_fail_two>'
E               and: ''
E               and: '    def pytest_runtest_setup(self, item):'
E               and: '        """'
E               and: "        Pytest hook to modify the test before it's run."
E               and: '    '
E               and: '        :param item:'
E               and: '            The test item.'
E               and: '        """'
E               and: '        if not self._has_flaky_attributes(item):'
E               and: "            if hasattr(item, 'iter_markers'):"
E               and: "                for marker in item.iter_markers(name='flaky'):"
E               and: '>                   self._make_test_flaky(item, *marker.args, **marker.kwargs)'
E               and: "E                   TypeError: _make_test_flaky() got an unexpected keyword argument 'reruns'"
E               and: ''
E               and: '/usr/lib/python3.8/site-packages/flaky/flaky_pytest_plugin.py:244: TypeError'
E               and: '===Flaky Test Report==='
E               and: ''
E               and: 'test_pass failed (1 runs remaining out of 2).'
E               and: "\t<class 'Exception'>"
E               and: '\tFailure: 1'
E               and: '\t[<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]'
E               and: 'test_pass passed 1 out of the required 1 times. Success!'
E               and: 'test_pass failed (1 runs remaining out of 2).'
E               and: "\t<class 'Exception'>"
E               and: '\tFailure: 1'
E               and: '\t[<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]'
E               and: 'test_pass failed; it passed 0 out of the required 1 times.'
E               and: "\t<class 'Exception'>"
E               and: '\tFailure: 2'
E               and: '\t[<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]'
E               and: ''
E               and: '===End Flaky Test Report==='
E               and: '=========================== short test summary info ============================'
E               and: 'ERROR test_reruns_with_delay_marker.py::test_fail_two - TypeError: _make_test...'
E               and: '=============================== 1 error in 0.06s ==============================='
E           remains unmatched: '*UserWarning: Delay time between re-runs cannot be < 0. Using default value: 0'

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:341: Failed
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay_marker.py E                                       [100%]

==================================== ERRORS ====================================
_______________________ ERROR at setup of test_fail_two ________________________

self = <flaky.flaky_pytest_plugin.FlakyPlugin object at 0x7f49328ce550>
item = <Function test_fail_two>

    def pytest_runtest_setup(self, item):
        """
        Pytest hook to modify the test before it's run.

        :param item:
            The test item.
        """
        if not self._has_flaky_attributes(item):
            if hasattr(item, 'iter_markers'):
                for marker in item.iter_markers(name='flaky'):
>                   self._make_test_flaky(item, *marker.args, **marker.kwargs)
E                   TypeError: _make_test_flaky() got an unexpected keyword argument 'reruns'

/usr/lib/python3.8/site-packages/flaky/flaky_pytest_plugin.py:244: TypeError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_reruns_with_delay_marker.py::test_fail_two - TypeError: _make_test...
=============================== 1 error in 0.06s ===============================
_____________________________________________________________________ test_reruns_with_delay_marker[0] _____________________________________________________________________

__wrapped_mock_method__ = <function NonCallableMock.assert_called_with at 0x7f493298b4c0>, args = (<MagicMock id='139959062680624'>, 0), kwargs = {}
__tracebackhide__ = True, msg = 'expected call not found.\nExpected: mock(0)\nActual: not called.', __mock_self = <MagicMock id='139959062680624'>

    def assert_wrapper(
        __wrapped_mock_method__: Callable[..., Any], *args: Any, **kwargs: Any
    ) -> None:
        __tracebackhide__ = True
        try:
>           __wrapped_mock_method__(*args, **kwargs)

/usr/lib/python3.8/site-packages/pytest_mock/plugin.py:414:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <MagicMock id='139959062680624'>, args = (0,), kwargs = {}, expected = 'mock(0)', actual = 'not called.'
error_message = 'expected call not found.\nExpected: mock(0)\nActual: not called.'

    def assert_called_with(self, /, *args, **kwargs):
        """assert that the last call was made with the specified arguments.

        Raises an AssertionError if the args and keyword args passed in are
        different to the last call to the mock."""
        if self.call_args is None:
            expected = self._format_mock_call_signature(args, kwargs)
            actual = 'not called.'
            error_message = ('expected call not found.\nExpected: %s\nActual: %s'
                    % (expected, actual))
>           raise AssertionError(error_message)
E           AssertionError: expected call not found.
E           Expected: mock(0)
E           Actual: not called.

/usr/lib64/python3.8/unittest/mock.py:904: AssertionError

During handling of the above exception, another exception occurred:

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker1')>, delay_time = 0

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay_marker(testdir, delay_time):
        testdir.makepyfile(
            """
            import pytest

            @pytest.mark.flaky(reruns=2, reruns_delay={})
            def test_fail_two():
                assert False""".format(
                delay_time
            )
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest()

        if delay_time < 0:
            result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
            delay_time = 0

>       time.sleep.assert_called_with(delay_time)
E       AssertionError: expected call not found.
E       Expected: mock(0)
E       Actual: not called.

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:347: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker1
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay_marker.py E                                       [100%]

==================================== ERRORS ====================================
_______________________ ERROR at setup of test_fail_two ________________________

self = <flaky.flaky_pytest_plugin.FlakyPlugin object at 0x7f49328ce550>
item = <Function test_fail_two>

    def pytest_runtest_setup(self, item):
        """
        Pytest hook to modify the test before it's run.

        :param item:
            The test item.
        """
        if not self._has_flaky_attributes(item):
            if hasattr(item, 'iter_markers'):
                for marker in item.iter_markers(name='flaky'):
>                   self._make_test_flaky(item, *marker.args, **marker.kwargs)
E                   TypeError: _make_test_flaky() got an unexpected keyword argument 'reruns'

/usr/lib/python3.8/site-packages/flaky/flaky_pytest_plugin.py:244: TypeError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_reruns_with_delay_marker.py::test_fail_two - TypeError: _make_test...
=============================== 1 error in 0.07s ===============================
____________________________________________________________________ test_reruns_with_delay_marker[0.0] ____________________________________________________________________

__wrapped_mock_method__ = <function NonCallableMock.assert_called_with at 0x7f493298b4c0>, args = (<MagicMock id='139959059554848'>, 0.0), kwargs = {}
__tracebackhide__ = True, msg = 'expected call not found.\nExpected: mock(0.0)\nActual: not called.', __mock_self = <MagicMock id='139959059554848'>

    def assert_wrapper(
        __wrapped_mock_method__: Callable[..., Any], *args: Any, **kwargs: Any
    ) -> None:
        __tracebackhide__ = True
        try:
>           __wrapped_mock_method__(*args, **kwargs)

/usr/lib/python3.8/site-packages/pytest_mock/plugin.py:414:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <MagicMock id='139959059554848'>, args = (0.0,), kwargs = {}, expected = 'mock(0.0)', actual = 'not called.'
error_message = 'expected call not found.\nExpected: mock(0.0)\nActual: not called.'

    def assert_called_with(self, /, *args, **kwargs):
        """assert that the last call was made with the specified arguments.

        Raises an AssertionError if the args and keyword args passed in are
        different to the last call to the mock."""
        if self.call_args is None:
            expected = self._format_mock_call_signature(args, kwargs)
            actual = 'not called.'
            error_message = ('expected call not found.\nExpected: %s\nActual: %s'
                    % (expected, actual))
>           raise AssertionError(error_message)
E           AssertionError: expected call not found.
E           Expected: mock(0.0)
E           Actual: not called.

/usr/lib64/python3.8/unittest/mock.py:904: AssertionError

During handling of the above exception, another exception occurred:

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker2')>, delay_time = 0.0

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay_marker(testdir, delay_time):
        testdir.makepyfile(
            """
            import pytest

            @pytest.mark.flaky(reruns=2, reruns_delay={})
            def test_fail_two():
                assert False""".format(
                delay_time
            )
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest()

        if delay_time < 0:
            result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
            delay_time = 0

>       time.sleep.assert_called_with(delay_time)
E       AssertionError: expected call not found.
E       Expected: mock(0.0)
E       Actual: not called.

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:347: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker2
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay_marker.py E                                       [100%]

==================================== ERRORS ====================================
_______________________ ERROR at setup of test_fail_two ________________________

self = <flaky.flaky_pytest_plugin.FlakyPlugin object at 0x7f49328ce550>
item = <Function test_fail_two>

    def pytest_runtest_setup(self, item):
        """
        Pytest hook to modify the test before it's run.

        :param item:
            The test item.
        """
        if not self._has_flaky_attributes(item):
            if hasattr(item, 'iter_markers'):
                for marker in item.iter_markers(name='flaky'):
>                   self._make_test_flaky(item, *marker.args, **marker.kwargs)
E                   TypeError: _make_test_flaky() got an unexpected keyword argument 'reruns'

/usr/lib/python3.8/site-packages/flaky/flaky_pytest_plugin.py:244: TypeError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_reruns_with_delay_marker.py::test_fail_two - TypeError: _make_test...
=============================== 1 error in 0.06s ===============================
_____________________________________________________________________ test_reruns_with_delay_marker[1] _____________________________________________________________________

__wrapped_mock_method__ = <function NonCallableMock.assert_called_with at 0x7f493298b4c0>, args = (<MagicMock id='139959061640624'>, 1), kwargs = {}
__tracebackhide__ = True, msg = 'expected call not found.\nExpected: mock(1)\nActual: not called.', __mock_self = <MagicMock id='139959061640624'>

    def assert_wrapper(
        __wrapped_mock_method__: Callable[..., Any], *args: Any, **kwargs: Any
    ) -> None:
        __tracebackhide__ = True
        try:
>           __wrapped_mock_method__(*args, **kwargs)

/usr/lib/python3.8/site-packages/pytest_mock/plugin.py:414:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <MagicMock id='139959061640624'>, args = (1,), kwargs = {}, expected = 'mock(1)', actual = 'not called.'
error_message = 'expected call not found.\nExpected: mock(1)\nActual: not called.'

    def assert_called_with(self, /, *args, **kwargs):
        """assert that the last call was made with the specified arguments.

        Raises an AssertionError if the args and keyword args passed in are
        different to the last call to the mock."""
        if self.call_args is None:
            expected = self._format_mock_call_signature(args, kwargs)
            actual = 'not called.'
            error_message = ('expected call not found.\nExpected: %s\nActual: %s'
                    % (expected, actual))
>           raise AssertionError(error_message)
E           AssertionError: expected call not found.
E           Expected: mock(1)
E           Actual: not called.

/usr/lib64/python3.8/unittest/mock.py:904: AssertionError

During handling of the above exception, another exception occurred:

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker3')>, delay_time = 1

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay_marker(testdir, delay_time):
        testdir.makepyfile(
            """
            import pytest

            @pytest.mark.flaky(reruns=2, reruns_delay={})
            def test_fail_two():
                assert False""".format(
                delay_time
            )
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest()

        if delay_time < 0:
            result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
            delay_time = 0

>       time.sleep.assert_called_with(delay_time)
E       AssertionError: expected call not found.
E       Expected: mock(1)
E       Actual: not called.

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:347: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker3
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay_marker.py E                                       [100%]

==================================== ERRORS ====================================
_______________________ ERROR at setup of test_fail_two ________________________

self = <flaky.flaky_pytest_plugin.FlakyPlugin object at 0x7f49328ce550>
item = <Function test_fail_two>

    def pytest_runtest_setup(self, item):
        """
        Pytest hook to modify the test before it's run.

        :param item:
            The test item.
        """
        if not self._has_flaky_attributes(item):
            if hasattr(item, 'iter_markers'):
                for marker in item.iter_markers(name='flaky'):
>                   self._make_test_flaky(item, *marker.args, **marker.kwargs)
E                   TypeError: _make_test_flaky() got an unexpected keyword argument 'reruns'

/usr/lib/python3.8/site-packages/flaky/flaky_pytest_plugin.py:244: TypeError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_reruns_with_delay_marker.py::test_fail_two - TypeError: _make_test...
=============================== 1 error in 0.06s ===============================
____________________________________________________________________ test_reruns_with_delay_marker[2.5] ____________________________________________________________________

__wrapped_mock_method__ = <function NonCallableMock.assert_called_with at 0x7f493298b4c0>, args = (<MagicMock id='139959060143744'>, 2.5), kwargs = {}
__tracebackhide__ = True, msg = 'expected call not found.\nExpected: mock(2.5)\nActual: not called.', __mock_self = <MagicMock id='139959060143744'>

    def assert_wrapper(
        __wrapped_mock_method__: Callable[..., Any], *args: Any, **kwargs: Any
    ) -> None:
        __tracebackhide__ = True
        try:
>           __wrapped_mock_method__(*args, **kwargs)

/usr/lib/python3.8/site-packages/pytest_mock/plugin.py:414:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <MagicMock id='139959060143744'>, args = (2.5,), kwargs = {}, expected = 'mock(2.5)', actual = 'not called.'
error_message = 'expected call not found.\nExpected: mock(2.5)\nActual: not called.'

    def assert_called_with(self, /, *args, **kwargs):
        """assert that the last call was made with the specified arguments.

        Raises an AssertionError if the args and keyword args passed in are
        different to the last call to the mock."""
        if self.call_args is None:
            expected = self._format_mock_call_signature(args, kwargs)
            actual = 'not called.'
            error_message = ('expected call not found.\nExpected: %s\nActual: %s'
                    % (expected, actual))
>           raise AssertionError(error_message)
E           AssertionError: expected call not found.
E           Expected: mock(2.5)
E           Actual: not called.

/usr/lib64/python3.8/unittest/mock.py:904: AssertionError

During handling of the above exception, another exception occurred:

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker4')>, delay_time = 2.5

    @pytest.mark.parametrize("delay_time", [-1, 0, 0.0, 1, 2.5])
    def test_reruns_with_delay_marker(testdir, delay_time):
        testdir.makepyfile(
            """
            import pytest

            @pytest.mark.flaky(reruns=2, reruns_delay={})
            def test_fail_two():
                assert False""".format(
                delay_time
            )
        )

        time.sleep = mock.MagicMock()

        result = testdir.runpytest()

        if delay_time < 0:
            result.stdout.fnmatch_lines(
                "*UserWarning: Delay time between re-runs cannot be < 0. "
                "Using default value: 0"
            )
            delay_time = 0

>       time.sleep.assert_called_with(delay_time)
E       AssertionError: expected call not found.
E       Expected: mock(2.5)
E       Actual: not called.

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:347: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_reruns_with_delay_marker4
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_reruns_with_delay_marker.py E                                       [100%]

==================================== ERRORS ====================================
_______________________ ERROR at setup of test_fail_two ________________________

self = <flaky.flaky_pytest_plugin.FlakyPlugin object at 0x7f49328ce550>
item = <Function test_fail_two>

    def pytest_runtest_setup(self, item):
        """
        Pytest hook to modify the test before it's run.

        :param item:
            The test item.
        """
        if not self._has_flaky_attributes(item):
            if hasattr(item, 'iter_markers'):
                for marker in item.iter_markers(name='flaky'):
>                   self._make_test_flaky(item, *marker.args, **marker.kwargs)
E                   TypeError: _make_test_flaky() got an unexpected keyword argument 'reruns'

/usr/lib/python3.8/site-packages/flaky/flaky_pytest_plugin.py:244: TypeError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_reruns_with_delay_marker.py::test_fail_two - TypeError: _make_test...
=============================== 1 error in 0.06s ===============================
_____________________________________________________________ test_rerun_on_setup_class_with_error_with_reruns _____________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_setup_class_with_error_with_reruns0')>

    def test_rerun_on_setup_class_with_error_with_reruns(testdir):
        """
         Case: setup_class throwing error on the first execution for parametrized test
        """
        testdir.makepyfile(
            """
            import pytest

            pass_fixture = False

            class TestFoo(object):
                @classmethod
                def setup_class(cls):
                    global pass_fixture
                    if not pass_fixture:
                        pass_fixture = True
                        assert False
                    assert True
                @pytest.mark.parametrize('param', [1, 2, 3])
                def test_pass(self, param):
                    assert param"""
        )
        result = testdir.runpytest("--reruns", "1")
>       assert_outcomes(result, passed=3, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:375:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:41: in assert_outcomes
    check_outcome_field(outcomes, "passed", passed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'errors': 3}, field_name = 'passed', expected_value = 3

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.passed has unexpected value. Expected '3' but got '0'
E       assert 0 == 3

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_setup_class_with_error_with_reruns0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 3 items

test_rerun_on_setup_class_with_error_with_reruns.py EEE                  [100%]

==================================== ERRORS ====================================
____________________ ERROR at setup of TestFoo.test_pass[1] ____________________

cls = <class 'test_rerun_on_setup_class_with_error_with_reruns.TestFoo'>

    @classmethod
    def setup_class(cls):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_setup_class_with_error_with_reruns.py:11: AssertionError
____________________ ERROR at setup of TestFoo.test_pass[2] ____________________

cls = <class 'test_rerun_on_setup_class_with_error_with_reruns.TestFoo'>

    @classmethod
    def setup_class(cls):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_setup_class_with_error_with_reruns.py:11: AssertionError
____________________ ERROR at setup of TestFoo.test_pass[3] ____________________

cls = <class 'test_rerun_on_setup_class_with_error_with_reruns.TestFoo'>

    @classmethod
    def setup_class(cls):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_setup_class_with_error_with_reruns.py:11: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_rerun_on_setup_class_with_error_with_reruns.py::TestFoo::test_pass[1]
ERROR test_rerun_on_setup_class_with_error_with_reruns.py::TestFoo::test_pass[2]
ERROR test_rerun_on_setup_class_with_error_with_reruns.py::TestFoo::test_pass[3]
============================== 3 errors in 0.06s ===============================
_________________________________________________________ test_rerun_on_class_scope_fixture_with_error_with_reruns _________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_class_scope_fixture_with_error_with_reruns0')>

    def test_rerun_on_class_scope_fixture_with_error_with_reruns(testdir):
        """
        Case: Class scope fixture throwing error on the first execution
        for parametrized test
        """
        testdir.makepyfile(
            """
            import pytest

            pass_fixture = False

            class TestFoo(object):

                @pytest.fixture(scope="class")
                def setup_fixture(self):
                    global pass_fixture
                    if not pass_fixture:
                        pass_fixture = True
                        assert False
                    assert True
                @pytest.mark.parametrize('param', [1, 2, 3])
                def test_pass(self, setup_fixture, param):
                    assert param"""
        )
        result = testdir.runpytest("--reruns", "1")
>       assert_outcomes(result, passed=3, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:403:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:41: in assert_outcomes
    check_outcome_field(outcomes, "passed", passed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'errors': 3}, field_name = 'passed', expected_value = 3

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.passed has unexpected value. Expected '3' but got '0'
E       assert 0 == 3

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_class_scope_fixture_with_error_with_reruns0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 3 items

test_rerun_on_class_scope_fixture_with_error_with_reruns.py EEE          [100%]

==================================== ERRORS ====================================
____________________ ERROR at setup of TestFoo.test_pass[1] ____________________

self = <test_rerun_on_class_scope_fixture_with_error_with_reruns.TestFoo object at 0x7f4ac2022820>

    @pytest.fixture(scope="class")
    def setup_fixture(self):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_class_scope_fixture_with_error_with_reruns.py:12: AssertionError
____________________ ERROR at setup of TestFoo.test_pass[2] ____________________

self = <test_rerun_on_class_scope_fixture_with_error_with_reruns.TestFoo object at 0x7f4ac2022820>

    @pytest.fixture(scope="class")
    def setup_fixture(self):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_class_scope_fixture_with_error_with_reruns.py:12: AssertionError
____________________ ERROR at setup of TestFoo.test_pass[3] ____________________

self = <test_rerun_on_class_scope_fixture_with_error_with_reruns.TestFoo object at 0x7f4ac2022820>

    @pytest.fixture(scope="class")
    def setup_fixture(self):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_class_scope_fixture_with_error_with_reruns.py:12: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_rerun_on_class_scope_fixture_with_error_with_reruns.py::TestFoo::test_pass[1]
ERROR test_rerun_on_class_scope_fixture_with_error_with_reruns.py::TestFoo::test_pass[2]
ERROR test_rerun_on_class_scope_fixture_with_error_with_reruns.py::TestFoo::test_pass[3]
============================== 3 errors in 0.06s ===============================
_________________________________________________________________ test_rerun_on_module_fixture_with_reruns _________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_module_fixture_with_reruns0')>

    def test_rerun_on_module_fixture_with_reruns(testdir):
        """
        Case: Module scope fixture is not re-executed when class scope fixture throwing
        error on the first execution for parametrized test
        """
        testdir.makepyfile(
            """
            import pytest

            pass_fixture = False

            @pytest.fixture(scope='module')
            def module_fixture():
                assert not pass_fixture

            class TestFoo(object):
                @pytest.fixture(scope="class")
                def setup_fixture(self):
                    global pass_fixture
                    if not pass_fixture:
                        pass_fixture = True
                        assert False
                    assert True
                def test_pass_1(self, module_fixture, setup_fixture):
                    assert True

                def test_pass_2(self, module_fixture, setup_fixture):
                    assert True"""
        )
        result = testdir.runpytest("--reruns", "1")
>       assert_outcomes(result, passed=2, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:436:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:41: in assert_outcomes
    check_outcome_field(outcomes, "passed", passed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'errors': 2}, field_name = 'passed', expected_value = 2

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.passed has unexpected value. Expected '2' but got '0'
E       assert 0 == 2

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_module_fixture_with_reruns0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 2 items

test_rerun_on_module_fixture_with_reruns.py EE                           [100%]

==================================== ERRORS ====================================
____________________ ERROR at setup of TestFoo.test_pass_1 _____________________

self = <test_rerun_on_module_fixture_with_reruns.TestFoo object at 0x7f4ac1f82af0>

    @pytest.fixture(scope="class")
    def setup_fixture(self):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_module_fixture_with_reruns.py:15: AssertionError
____________________ ERROR at setup of TestFoo.test_pass_2 _____________________

self = <test_rerun_on_module_fixture_with_reruns.TestFoo object at 0x7f4ac1f82af0>

    @pytest.fixture(scope="class")
    def setup_fixture(self):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_module_fixture_with_reruns.py:15: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_rerun_on_module_fixture_with_reruns.py::TestFoo::test_pass_1 - ass...
ERROR test_rerun_on_module_fixture_with_reruns.py::TestFoo::test_pass_2 - ass...
============================== 2 errors in 0.06s ===============================
________________________________________________________________ test_rerun_on_session_fixture_with_reruns _________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_session_fixture_with_reruns0')>

    def test_rerun_on_session_fixture_with_reruns(testdir):
        """
        Case: Module scope fixture is not re-executed when class scope fixture
        throwing error on the first execution for parametrized test
        """
        testdir.makepyfile(
            """
            import pytest

            pass_fixture = False

            @pytest.fixture(scope='session')
            def session_fixture():
                assert not pass_fixture

            class TestFoo(object):
                @pytest.fixture(scope="class")
                def setup_fixture(self):
                    global pass_fixture
                    if not pass_fixture:
                        pass_fixture = True
                        assert False
                    assert True

                def test_pass_1(self, session_fixture, setup_fixture):
                    assert True
                def test_pass_2(self, session_fixture, setup_fixture):
                    assert True"""
        )
        result = testdir.runpytest("--reruns", "1")
>       assert_outcomes(result, passed=2, rerun=1)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:469:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:41: in assert_outcomes
    check_outcome_field(outcomes, "passed", passed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'errors': 2}, field_name = 'passed', expected_value = 2

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.passed has unexpected value. Expected '2' but got '0'
E       assert 0 == 2

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_on_session_fixture_with_reruns0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 2 items

test_rerun_on_session_fixture_with_reruns.py EE                          [100%]

==================================== ERRORS ====================================
____________________ ERROR at setup of TestFoo.test_pass_1 _____________________

self = <test_rerun_on_session_fixture_with_reruns.TestFoo object at 0x7f4ac1fafe20>

    @pytest.fixture(scope="class")
    def setup_fixture(self):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_session_fixture_with_reruns.py:15: AssertionError
____________________ ERROR at setup of TestFoo.test_pass_2 _____________________

self = <test_rerun_on_session_fixture_with_reruns.TestFoo object at 0x7f4ac1fafe20>

    @pytest.fixture(scope="class")
    def setup_fixture(self):
        global pass_fixture
        if not pass_fixture:
            pass_fixture = True
>           assert False
E           assert False

test_rerun_on_session_fixture_with_reruns.py:15: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_rerun_on_session_fixture_with_reruns.py::TestFoo::test_pass_1 - as...
ERROR test_rerun_on_session_fixture_with_reruns.py::TestFoo::test_pass_2 - as...
============================== 2 errors in 0.06s ===============================
_______________________________________________________________________ test_execution_count_exposed _______________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_execution_count_exposed0')>

    def test_execution_count_exposed(testdir):
        testdir.makepyfile("def test_pass(): assert True")
        testdir.makeconftest(
            """
            def pytest_runtest_teardown(item):
                assert item.execution_count == 3"""
        )
        result = testdir.runpytest("--reruns", "2")
>       assert_outcomes(result, passed=3, rerun=2)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:480:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:41: in assert_outcomes
    check_outcome_field(outcomes, "passed", passed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'errors': 1, 'passed': 1}, field_name = 'passed', expected_value = 3

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.passed has unexpected value. Expected '3' but got '1'
E       assert 1 == 3

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_execution_count_exposed0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_execution_count_exposed.py .E                                       [100%]

==================================== ERRORS ====================================
________________________ ERROR at teardown of test_pass ________________________

item = <Function test_pass>

    def pytest_runtest_teardown(item):
>       assert item.execution_count == 3
E       AttributeError: 'Function' object has no attribute 'execution_count'

conftest.py:2: AttributeError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
ERROR test_execution_count_exposed.py::test_pass - AttributeError: 'Function'...
========================== 1 passed, 1 error in 0.05s ==========================
____________________________________________________________________________ test_rerun_report _____________________________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_rerun_report0')>

    def test_rerun_report(testdir):
        testdir.makepyfile("def test_pass(): assert False")
        testdir.makeconftest(
            """
            def pytest_runtest_logreport(report):
                assert hasattr(report, 'rerun')
                assert isinstance(report.rerun, int)
                assert report.rerun <= 2
            """
        )
        result = testdir.runpytest("--reruns", "2")
>       assert_outcomes(result, failed=1, rerun=2, passed=0)

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:494:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:43: in assert_outcomes
    check_outcome_field(outcomes, "failed", failed)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {}, field_name = 'failed', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.failed has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_rerun_report0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_rerun_report.py
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/_pytest/main.py", line 269, in wrap_session
INTERNALERROR>     session.exitstatus = doit(config, session) or 0
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/_pytest/main.py", line 323, in _main
INTERNALERROR>     config.hook.pytest_runtestloop(session=session)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/hooks.py", line 286, in __call__
INTERNALERROR>     return self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 337, in traced_hookexec
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 52, in from_call
INTERNALERROR>     result = func()
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 335, in <lambda>
INTERNALERROR>     outcome = _Result.from_call(lambda: oldcall(hook, hook_impls, kwargs))
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 84, in <lambda>
INTERNALERROR>     self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/_pytest/main.py", line 348, in pytest_runtestloop
INTERNALERROR>     item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/hooks.py", line 286, in __call__
INTERNALERROR>     return self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 337, in traced_hookexec
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 52, in from_call
INTERNALERROR>     result = func()
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 335, in <lambda>
INTERNALERROR>     outcome = _Result.from_call(lambda: oldcall(hook, hook_impls, kwargs))
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 84, in <lambda>
INTERNALERROR>     self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/flaky/flaky_pytest_plugin.py", line 94, in pytest_runtest_protocol
INTERNALERROR>     self.runner.pytest_runtest_protocol(item, nextitem)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/_pytest/runner.py", line 109, in pytest_runtest_protocol
INTERNALERROR>     runtestprotocol(item, nextitem=nextitem)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/_pytest/runner.py", line 120, in runtestprotocol
INTERNALERROR>     rep = call_and_report(item, "setup", log)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/flaky/flaky_pytest_plugin.py", line 154, in call_and_report
INTERNALERROR>     hook.pytest_runtest_logreport(report=report)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/hooks.py", line 286, in __call__
INTERNALERROR>     return self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 337, in traced_hookexec
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 52, in from_call
INTERNALERROR>     result = func()
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 335, in <lambda>
INTERNALERROR>     outcome = _Result.from_call(lambda: oldcall(hook, hook_impls, kwargs))
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/manager.py", line 84, in <lambda>
INTERNALERROR>     self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/usr/lib/python3.8/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/tmp/pytest-of-tkloczko/pytest-22/test_rerun_report0/conftest.py", line 2, in pytest_runtest_logreport
INTERNALERROR>     assert hasattr(report, 'rerun')
INTERNALERROR> AssertionError: assert False
INTERNALERROR>  +  where False = hasattr(<TestReport 'test_rerun_report.py::test_pass' when='setup' outcome='passed'>, 'rerun')

============================ no tests ran in 0.05s =============================
_______________________________________________________________ test_only_rerun_flag[only_rerun_texts0-True] _______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag0')>, only_rerun_texts = ['AssertionError'], should_rerun = True

    @pytest.mark.parametrize(
        "only_rerun_texts, should_rerun",
        [
            (["AssertionError"], True),
            (["Assertion*"], True),
            (["Assertion"], True),
            (["ValueError"], False),
            ([""], True),
            (["AssertionError: "], True),
            (["AssertionError: ERR"], True),
            (["ERR"], True),
            (["AssertionError,ValueError"], False),
            (["AssertionError ValueError"], False),
            (["AssertionError", "ValueError"], True),
        ],
    )
    def test_only_rerun_flag(testdir, only_rerun_texts, should_rerun):
        testdir.makepyfile('def test_only_rerun(): raise AssertionError("ERR")')

        num_failed = 1
        num_passed = 0
        num_reruns = 1
        num_reruns_actual = num_reruns if should_rerun else 0

        pytest_args = ["--reruns", str(num_reruns)]
        for only_rerun_text in only_rerun_texts:
            pytest_args.extend(["--only-rerun", only_rerun_text])
        result = testdir.runpytest(*pytest_args)
>       assert_outcomes(
            result, passed=num_passed, failed=num_failed, rerun=num_reruns_actual
        )

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:540:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag0
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_only_rerun_flag.py F                                                [100%]

=================================== FAILURES ===================================
_______________________________ test_only_rerun ________________________________

>   def test_only_rerun(): raise AssertionError("ERR")
E   AssertionError: ERR

test_only_rerun_flag.py:1: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_only_rerun_flag.py::test_only_rerun - AssertionError: ERR
============================== 1 failed in 0.05s ===============================
_______________________________________________________________ test_only_rerun_flag[only_rerun_texts1-True] _______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag1')>, only_rerun_texts = ['Assertion*'], should_rerun = True

    @pytest.mark.parametrize(
        "only_rerun_texts, should_rerun",
        [
            (["AssertionError"], True),
            (["Assertion*"], True),
            (["Assertion"], True),
            (["ValueError"], False),
            ([""], True),
            (["AssertionError: "], True),
            (["AssertionError: ERR"], True),
            (["ERR"], True),
            (["AssertionError,ValueError"], False),
            (["AssertionError ValueError"], False),
            (["AssertionError", "ValueError"], True),
        ],
    )
    def test_only_rerun_flag(testdir, only_rerun_texts, should_rerun):
        testdir.makepyfile('def test_only_rerun(): raise AssertionError("ERR")')

        num_failed = 1
        num_passed = 0
        num_reruns = 1
        num_reruns_actual = num_reruns if should_rerun else 0

        pytest_args = ["--reruns", str(num_reruns)]
        for only_rerun_text in only_rerun_texts:
            pytest_args.extend(["--only-rerun", only_rerun_text])
        result = testdir.runpytest(*pytest_args)
>       assert_outcomes(
            result, passed=num_passed, failed=num_failed, rerun=num_reruns_actual
        )

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:540:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag1
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_only_rerun_flag.py F                                                [100%]

=================================== FAILURES ===================================
_______________________________ test_only_rerun ________________________________

>   def test_only_rerun(): raise AssertionError("ERR")
E   AssertionError: ERR

test_only_rerun_flag.py:1: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_only_rerun_flag.py::test_only_rerun - AssertionError: ERR
============================== 1 failed in 0.05s ===============================
_______________________________________________________________ test_only_rerun_flag[only_rerun_texts2-True] _______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag2')>, only_rerun_texts = ['Assertion'], should_rerun = True

    @pytest.mark.parametrize(
        "only_rerun_texts, should_rerun",
        [
            (["AssertionError"], True),
            (["Assertion*"], True),
            (["Assertion"], True),
            (["ValueError"], False),
            ([""], True),
            (["AssertionError: "], True),
            (["AssertionError: ERR"], True),
            (["ERR"], True),
            (["AssertionError,ValueError"], False),
            (["AssertionError ValueError"], False),
            (["AssertionError", "ValueError"], True),
        ],
    )
    def test_only_rerun_flag(testdir, only_rerun_texts, should_rerun):
        testdir.makepyfile('def test_only_rerun(): raise AssertionError("ERR")')

        num_failed = 1
        num_passed = 0
        num_reruns = 1
        num_reruns_actual = num_reruns if should_rerun else 0

        pytest_args = ["--reruns", str(num_reruns)]
        for only_rerun_text in only_rerun_texts:
            pytest_args.extend(["--only-rerun", only_rerun_text])
        result = testdir.runpytest(*pytest_args)
>       assert_outcomes(
            result, passed=num_passed, failed=num_failed, rerun=num_reruns_actual
        )

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:540:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag2
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_only_rerun_flag.py F                                                [100%]

=================================== FAILURES ===================================
_______________________________ test_only_rerun ________________________________

>   def test_only_rerun(): raise AssertionError("ERR")
E   AssertionError: ERR

test_only_rerun_flag.py:1: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_only_rerun_flag.py::test_only_rerun - AssertionError: ERR
============================== 1 failed in 0.05s ===============================
_______________________________________________________________ test_only_rerun_flag[only_rerun_texts4-True] _______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag4')>, only_rerun_texts = [''], should_rerun = True

    @pytest.mark.parametrize(
        "only_rerun_texts, should_rerun",
        [
            (["AssertionError"], True),
            (["Assertion*"], True),
            (["Assertion"], True),
            (["ValueError"], False),
            ([""], True),
            (["AssertionError: "], True),
            (["AssertionError: ERR"], True),
            (["ERR"], True),
            (["AssertionError,ValueError"], False),
            (["AssertionError ValueError"], False),
            (["AssertionError", "ValueError"], True),
        ],
    )
    def test_only_rerun_flag(testdir, only_rerun_texts, should_rerun):
        testdir.makepyfile('def test_only_rerun(): raise AssertionError("ERR")')

        num_failed = 1
        num_passed = 0
        num_reruns = 1
        num_reruns_actual = num_reruns if should_rerun else 0

        pytest_args = ["--reruns", str(num_reruns)]
        for only_rerun_text in only_rerun_texts:
            pytest_args.extend(["--only-rerun", only_rerun_text])
        result = testdir.runpytest(*pytest_args)
>       assert_outcomes(
            result, passed=num_passed, failed=num_failed, rerun=num_reruns_actual
        )

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:540:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag4
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_only_rerun_flag.py F                                                [100%]

=================================== FAILURES ===================================
_______________________________ test_only_rerun ________________________________

>   def test_only_rerun(): raise AssertionError("ERR")
E   AssertionError: ERR

test_only_rerun_flag.py:1: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_only_rerun_flag.py::test_only_rerun - AssertionError: ERR
============================== 1 failed in 0.05s ===============================
_______________________________________________________________ test_only_rerun_flag[only_rerun_texts5-True] _______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag5')>, only_rerun_texts = ['AssertionError: '], should_rerun = True

    @pytest.mark.parametrize(
        "only_rerun_texts, should_rerun",
        [
            (["AssertionError"], True),
            (["Assertion*"], True),
            (["Assertion"], True),
            (["ValueError"], False),
            ([""], True),
            (["AssertionError: "], True),
            (["AssertionError: ERR"], True),
            (["ERR"], True),
            (["AssertionError,ValueError"], False),
            (["AssertionError ValueError"], False),
            (["AssertionError", "ValueError"], True),
        ],
    )
    def test_only_rerun_flag(testdir, only_rerun_texts, should_rerun):
        testdir.makepyfile('def test_only_rerun(): raise AssertionError("ERR")')

        num_failed = 1
        num_passed = 0
        num_reruns = 1
        num_reruns_actual = num_reruns if should_rerun else 0

        pytest_args = ["--reruns", str(num_reruns)]
        for only_rerun_text in only_rerun_texts:
            pytest_args.extend(["--only-rerun", only_rerun_text])
        result = testdir.runpytest(*pytest_args)
>       assert_outcomes(
            result, passed=num_passed, failed=num_failed, rerun=num_reruns_actual
        )

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:540:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag5
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_only_rerun_flag.py F                                                [100%]

=================================== FAILURES ===================================
_______________________________ test_only_rerun ________________________________

>   def test_only_rerun(): raise AssertionError("ERR")
E   AssertionError: ERR

test_only_rerun_flag.py:1: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_only_rerun_flag.py::test_only_rerun - AssertionError: ERR
============================== 1 failed in 0.05s ===============================
_______________________________________________________________ test_only_rerun_flag[only_rerun_texts6-True] _______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag6')>, only_rerun_texts = ['AssertionError: ERR'], should_rerun = True

    @pytest.mark.parametrize(
        "only_rerun_texts, should_rerun",
        [
            (["AssertionError"], True),
            (["Assertion*"], True),
            (["Assertion"], True),
            (["ValueError"], False),
            ([""], True),
            (["AssertionError: "], True),
            (["AssertionError: ERR"], True),
            (["ERR"], True),
            (["AssertionError,ValueError"], False),
            (["AssertionError ValueError"], False),
            (["AssertionError", "ValueError"], True),
        ],
    )
    def test_only_rerun_flag(testdir, only_rerun_texts, should_rerun):
        testdir.makepyfile('def test_only_rerun(): raise AssertionError("ERR")')

        num_failed = 1
        num_passed = 0
        num_reruns = 1
        num_reruns_actual = num_reruns if should_rerun else 0

        pytest_args = ["--reruns", str(num_reruns)]
        for only_rerun_text in only_rerun_texts:
            pytest_args.extend(["--only-rerun", only_rerun_text])
        result = testdir.runpytest(*pytest_args)
>       assert_outcomes(
            result, passed=num_passed, failed=num_failed, rerun=num_reruns_actual
        )

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:540:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag6
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_only_rerun_flag.py F                                                [100%]

=================================== FAILURES ===================================
_______________________________ test_only_rerun ________________________________

>   def test_only_rerun(): raise AssertionError("ERR")
E   AssertionError: ERR

test_only_rerun_flag.py:1: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_only_rerun_flag.py::test_only_rerun - AssertionError: ERR
============================== 1 failed in 0.05s ===============================
_______________________________________________________________ test_only_rerun_flag[only_rerun_texts7-True] _______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag7')>, only_rerun_texts = ['ERR'], should_rerun = True

    @pytest.mark.parametrize(
        "only_rerun_texts, should_rerun",
        [
            (["AssertionError"], True),
            (["Assertion*"], True),
            (["Assertion"], True),
            (["ValueError"], False),
            ([""], True),
            (["AssertionError: "], True),
            (["AssertionError: ERR"], True),
            (["ERR"], True),
            (["AssertionError,ValueError"], False),
            (["AssertionError ValueError"], False),
            (["AssertionError", "ValueError"], True),
        ],
    )
    def test_only_rerun_flag(testdir, only_rerun_texts, should_rerun):
        testdir.makepyfile('def test_only_rerun(): raise AssertionError("ERR")')

        num_failed = 1
        num_passed = 0
        num_reruns = 1
        num_reruns_actual = num_reruns if should_rerun else 0

        pytest_args = ["--reruns", str(num_reruns)]
        for only_rerun_text in only_rerun_texts:
            pytest_args.extend(["--only-rerun", only_rerun_text])
        result = testdir.runpytest(*pytest_args)
>       assert_outcomes(
            result, passed=num_passed, failed=num_failed, rerun=num_reruns_actual
        )

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:540:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag7
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_only_rerun_flag.py F                                                [100%]

=================================== FAILURES ===================================
_______________________________ test_only_rerun ________________________________

>   def test_only_rerun(): raise AssertionError("ERR")
E   AssertionError: ERR

test_only_rerun_flag.py:1: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_only_rerun_flag.py::test_only_rerun - AssertionError: ERR
============================== 1 failed in 0.05s ===============================
______________________________________________________________ test_only_rerun_flag[only_rerun_texts10-True] _______________________________________________________________

testdir = <Testdir local('/tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag10')>, only_rerun_texts = ['AssertionError', 'ValueError'], should_rerun = True

    @pytest.mark.parametrize(
        "only_rerun_texts, should_rerun",
        [
            (["AssertionError"], True),
            (["Assertion*"], True),
            (["Assertion"], True),
            (["ValueError"], False),
            ([""], True),
            (["AssertionError: "], True),
            (["AssertionError: ERR"], True),
            (["ERR"], True),
            (["AssertionError,ValueError"], False),
            (["AssertionError ValueError"], False),
            (["AssertionError", "ValueError"], True),
        ],
    )
    def test_only_rerun_flag(testdir, only_rerun_texts, should_rerun):
        testdir.makepyfile('def test_only_rerun(): raise AssertionError("ERR")')

        num_failed = 1
        num_passed = 0
        num_reruns = 1
        num_reruns_actual = num_reruns if should_rerun else 0

        pytest_args = ["--reruns", str(num_reruns)]
        for only_rerun_text in only_rerun_texts:
            pytest_args.extend(["--only-rerun", only_rerun_text])
        result = testdir.runpytest(*pytest_args)
>       assert_outcomes(
            result, passed=num_passed, failed=num_failed, rerun=num_reruns_actual
        )

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:540:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:46: in assert_outcomes
    check_outcome_field(outcomes, "rerun", rerun)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

outcomes = {'failed': 1}, field_name = 'rerun', expected_value = 1

    def check_outcome_field(outcomes, field_name, expected_value):
        field_value = outcomes.get(field_name, 0)
>       assert (
            field_value == expected_value
        ), "outcomes.{} has unexpected value. Expected '{}' but got '{}'".format(
            field_name, expected_value, field_value
        )
E       AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
E       assert 0 == 1

/home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/test_pytest_rerunfailures.py:30: AssertionError
--------------------------------------------------------------------------- Captured stdout call ---------------------------------------------------------------------------
============================= test session starts ==============================
platform linux -- Python 3.8.9, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
rootdir: /tmp/pytest-of-tkloczko/pytest-22/test_only_rerun_flag10
plugins: rerunfailures-9.1.1, forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, asyncio-0.15.1, toolbox-0.5, xprocess-0.17.1, flaky-3.7.0, requests-mock-1.9.2, aiohttp-0.3.0, checkdocs-2.7.0, mock-3.6.1, hypothesis-6.13.2
collected 1 item

test_only_rerun_flag.py F                                                [100%]

=================================== FAILURES ===================================
_______________________________ test_only_rerun ________________________________

>   def test_only_rerun(): raise AssertionError("ERR")
E   AssertionError: ERR

test_only_rerun_flag.py:1: AssertionError
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
=========================== short test summary info ============================
FAILED test_only_rerun_flag.py::test_only_rerun - AssertionError: ERR
============================== 1 failed in 0.05s ===============================
===Flaky Test Report===

test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_without_options0/test_reruns_if_flaky_mark_is_called_without_options.py:10>]
test_pass passed 1 out of the required 1 times. Success!
test_pass failed (1 runs remaining out of 2).
        <class 'Exception'>
        Failure: 1
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]
test_pass failed; it passed 0 out of the required 1 times.
        <class 'Exception'>
        Failure: 2
        [<TracebackEntry /tmp/pytest-of-tkloczko/pytest-22/test_reruns_if_flaky_mark_is_called_with_positional_argument0/test_reruns_if_flaky_mark_is_called_with_positional_argument.py:10>]

===End Flaky Test Report===
========================================================================= short test summary info ==========================================================================
SKIPPED [1] test_pytest_rerunfailures.py:286: --result-log removed in pytest>=6.1
FAILED test_pytest_rerunfailures.py::test_error_when_run_with_pdb - Failed: line 'ERROR: --reruns incompatible with --pdb' not found in output
FAILED test_pytest_rerunfailures.py::test_rerun_fails_after_consistent_setup_failure - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_rerun_passes_after_temporary_setup_failure - AssertionError: outcomes.passed has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_rerun_fails_after_consistent_test_failure - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_rerun_passes_after_temporary_test_failure - AssertionError: outcomes.passed has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_rerun_passes_after_temporary_test_failure_with_flaky_mark - AssertionError: outcomes.passed has unexpected value. Expected '1' ...
FAILED test_pytest_rerunfailures.py::test_reruns_if_flaky_mark_is_called_without_options - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_reruns_if_flaky_mark_is_called_with_positional_argument - AssertionError: outcomes.passed has unexpected value. Expected '1' bu...
FAILED test_pytest_rerunfailures.py::test_no_extra_test_summary_for_reruns_by_default - AssertionError: assert '1 rerun' in '============================= test session s...
FAILED test_pytest_rerunfailures.py::test_extra_test_summary_for_reruns - Failed: line 'RERUN test_*:*' not found in output
FAILED test_pytest_rerunfailures.py::test_verbose - Failed: line 'test_*:* RERUN*' not found in output
FAILED test_pytest_rerunfailures.py::test_rerun_on_class_setup_error_with_reruns - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay[-1] - Failed: nomatch: '*UserWarning: Delay time between re-runs cannot be < 0. Using default value: 0'
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay[0] - AssertionError: expected call not found.
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay[0.0] - AssertionError: expected call not found.
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay[1] - AssertionError: expected call not found.
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay[2.5] - AssertionError: expected call not found.
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay_marker[-1] - Failed: nomatch: '*UserWarning: Delay time between re-runs cannot be < 0. Using default value: 0'
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay_marker[0] - AssertionError: expected call not found.
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay_marker[0.0] - AssertionError: expected call not found.
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay_marker[1] - AssertionError: expected call not found.
FAILED test_pytest_rerunfailures.py::test_reruns_with_delay_marker[2.5] - AssertionError: expected call not found.
FAILED test_pytest_rerunfailures.py::test_rerun_on_setup_class_with_error_with_reruns - AssertionError: outcomes.passed has unexpected value. Expected '3' but got '0'
FAILED test_pytest_rerunfailures.py::test_rerun_on_class_scope_fixture_with_error_with_reruns - AssertionError: outcomes.passed has unexpected value. Expected '3' but go...
FAILED test_pytest_rerunfailures.py::test_rerun_on_module_fixture_with_reruns - AssertionError: outcomes.passed has unexpected value. Expected '2' but got '0'
FAILED test_pytest_rerunfailures.py::test_rerun_on_session_fixture_with_reruns - AssertionError: outcomes.passed has unexpected value. Expected '2' but got '0'
FAILED test_pytest_rerunfailures.py::test_execution_count_exposed - AssertionError: outcomes.passed has unexpected value. Expected '3' but got '1'
FAILED test_pytest_rerunfailures.py::test_rerun_report - AssertionError: outcomes.failed has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_only_rerun_flag[only_rerun_texts0-True] - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_only_rerun_flag[only_rerun_texts1-True] - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_only_rerun_flag[only_rerun_texts2-True] - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_only_rerun_flag[only_rerun_texts4-True] - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_only_rerun_flag[only_rerun_texts5-True] - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_only_rerun_flag[only_rerun_texts6-True] - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_only_rerun_flag[only_rerun_texts7-True] - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
FAILED test_pytest_rerunfailures.py::test_only_rerun_flag[only_rerun_texts10-True] - AssertionError: outcomes.rerun has unexpected value. Expected '1' but got '0'
================================================================ 36 failed, 12 passed, 1 skipped in 14.60s =================================================================
icemac commented 3 years ago

GHA can reproduce these problems for pytest master, see https://github.com/pytest-dev/pytest-rerunfailures/runs/2662425068?check_suite_focus=true

kloczek commented 3 years ago

Good 😊 (I mean .. bad 😊 ) So what it could be? pytest issue or something which needs to be addressed in pytest-rerunfailures code?🤔

icemac commented 3 years ago

@kloczek Sorry I was wrong about GHA: pytest switched the default branch from master to main, this broke GHA. I fixed this in #160 and cannot reproduce the problems you had running against pytest main.

icemac commented 3 years ago

Locally the tests are fine, too; but I am testing against master of pytest-rerunfailures – what happens, if you test against master?

kloczek commented 3 years ago

tox is usimg pytest inside virtual env and testing tox is OK. Because of that now I think that it is not matter of pytest per se but it may be matter of one of the pytest extensions lited on top of that ticket.

kloczek commented 3 years ago

BTW I just found that I was wrong abou tox. Looks lik etox produces error:

+ /usr/bin/python3 -Bm tox --skip-missing-interpreters
.tox create: /home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/.tox/.tox
.tox installdeps: tox >= 3.17.1
GLOB sdist-make: /home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/setup.py
linting create: /home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/.tox/linting
linting installdeps: pre-commit>=1.11.0
linting installed: appdirs==1.4.4,cfgv==3.3.0,distlib==0.3.1,filelock==3.0.12,identify==2.2.6,nodeenv==1.6.0,pre-commit==2.13.0,PyYAML==5.4.1,six==1.16.0,toml==0.10.2,virtualenv==20.4.7
linting run-test-pre: PYTHONHASHSEED='276315336'
linting run-test: commands[0] | pre-commit run --all-files --show-diff-on-failure
An error has occurred: FatalError: git failed. Is it installed, and are you in a Git repository directory?
Check the log at /home/tkloczko/.cache/pre-commit/pre-commit.log
ERROR: InvocationError for command /home/tkloczko/rpmbuild/BUILD/pytest-rerunfailures-9.1.1/.tox/linting/bin/pre-commit run --all-files --show-diff-on-failure (exited with code 1)
icemac commented 3 years ago

So you think the issue is invalid?

sallner commented 3 years ago

At least the last error implies that git is not working correctly, so pre-commit is failing. Is tox in this case running from a checkout of pytest-rerunfailures or from the release? In the latter case, the linting checker might not work as intended but should also not be needed to test functionality, and could be skipped.

kloczek commented 3 years ago

I think that issue is a it deeper. Looks like the test suite is used on actual developement and as set of final checks before actual commit. I have notbing against that kind of bits but IMO by default pytest or tox shoud be performinfg actual functional code testing than for examp,e checkiing "do I run in in working git tree?". IMO bits used on acrtual development cycle should be not default set of tests. Behaviour like here is possible sometimes to see but I would say that +99.8% test suites is focused on testing the code before it will be part of the system resources than doing set of final chacks before actula commit.

kloczek commented 4 months ago

Closing because this ticket is now outdated.