Use latest version of pytest under Python >= 3.6 since it contains a bug
fix for running under Python 3.10.
@@ -7,7 +7,9 @@ codecov==2.1.10
coverage==4.5.4
requests
requests_mock
-pytest==5.3.2
+# 5.3.2 is latest version which still supports Python 3.5, >= 6.2.5 is needed for Python 3.10
+pytest==5.3.2; python_version <= '3.5'
+pytest==6.2.5; python_version >= '3.6'
cryptography==3.2.1
# NOTE: Only needed by nttcis loadbalancer driver
pyopenssl==19.1.0
