@@ -28,11 +28,13 @@ def check(session):
2828@nox .session (name = "tests" , tags = ["tests" ])
2929def run_tests (session ):
3030 """Run unit tests and generate a coverage report"""
31+ pyproject = nox .project .load_toml ("pyproject.toml" )
32+ session .install (* nox .project .dependency_groups (pyproject , "test" ))
3133 # SciPy doesn't have wheels on PyPy
3234 if platform .python_implementation () == "PyPy" :
33- session .install ("-e" , ".[test] " , silent = False )
35+ session .install ("-e. " , silent = False )
3436 else :
35- session .install ("-e" , ".[test, scipy]" , silent = False )
37+ session .install ("-e" , ".[scipy]" , silent = False )
3638 session .run ("pytest" , "--cov=autograd" , "--cov-report=xml" , "--cov-append" , * session .posargs )
3739
3840
@@ -46,7 +48,9 @@ def ruff(session):
4648@nox .session (name = "nightly-tests" , tags = ["tests" ])
4749def run_nightly_tests (session ):
4850 """Run tests against nightly versions of dependencies"""
49- session .install ("-e" , ".[test]" , silent = False )
51+ session .install ("-e." , silent = False )
52+ pyproject = nox .project .load_toml ("pyproject.toml" )
53+ session .install (* nox .project .dependency_groups (pyproject , "test" ))
5054 # SciPy doesn't have wheels on PyPy
5155 if platform .python_implementation () == "PyPy" :
5256 session .install (
0 commit comments