def test_random():
import random
assert random.choice([1,2,3,4]) == 2
It fails randomly.
I'd like to use pytest-rerunfailures to run it copule of times and store log for every rerun if failed.
Now pytest-logger stores only last run, so if finally test passes I do not have logs from reruns.
Do you have any idea how to connect those two plugins so I'll have logs from reruns? Then I could analyze what was wrong in random test
Hi
Let's have a test:
It fails randomly. I'd like to use pytest-rerunfailures to run it copule of times and store log for every rerun if failed. Now pytest-logger stores only last run, so if finally test passes I do not have logs from reruns.
Do you have any idea how to connect those two plugins so I'll have logs from reruns? Then I could analyze what was wrong in random test