pytest-flakefinder:

pip install pytest-flakefinder
And then run every test multiple times (50 by default):

pytest --flake-finder --flake-runs=5 tests/test_failing_test.py

This plugin doesn't work with -n flag from pytest-xdist.

There is another plugin pytest-repeat, but it doesn't work with unittest.

Run tests in a random order