Closed jhanm12 closed 9 months ago
random order works fine if "-p no:cacheprovider" is not provided.
Working Cases:
pytest test_dummy.py (Works) pytest test_dummy.py --random-order (Works - Random Order Enabled) pytest test_dummy.py -p no:cacheprovider -p no:random_order (Works - Both Cache & Random Order Disabled)
Not Working Cases:
pytest test_dummy.py -p no:cacheprovider (Does Not Work - Only Cache Disabled) pytest test_dummy.py -p no:cacheprovider --random-order (Does Not Work - Cache Disabled & Random Order Enabled)
@jbasko Can you please check this.
pytest-random-order - Always assumes that the cacheprovider plugin is always active. It fails in this below case:
In an env:
If we run a pytest script with this -p no:cacheprovider
Had to disable random order plugin - To make it work when disable cache parameter is set.
Please Refer this : https://github.com/pytest-dev/pytest/issues/9250