File tree Expand file tree Collapse file tree 1 file changed +15
-7
lines changed
Expand file tree Collapse file tree 1 file changed +15
-7
lines changed Original file line number Diff line number Diff line change @@ -15,13 +15,21 @@ def test_demo_project_generation(robust_python_demo_with_setup: Path) -> None:
1515@pytest .mark .parametrize ("session" , GLOBAL_NOX_SESSIONS )
1616def test_demo_project_nox_session (robust_demo : Path , session : str ) -> None :
1717 command : list [str ] = ["nox" , "-s" , session ]
18- subprocess .run (
19- command ,
20- cwd = robust_demo ,
21- capture_output = True ,
22- text = True ,
23- check = True
24- )
18+ try :
19+ subprocess .run (
20+ command ,
21+ cwd = robust_demo ,
22+ stdout = subprocess .PIPE ,
23+ stderr = subprocess .STDOUT ,
24+ text = True ,
25+ check = True
26+ )
27+ except subprocess .CalledProcessError as e :
28+ pytest .fail (
29+ f"nox session '{ session } ' failed with exit code { e .returncode } \n "
30+ f"{ '-' * 20 } STDOUT { '-' * 20 } \n { e .stdout } \n "
31+ f"{ '-' * 20 } STDERR { '-' * 20 } \n { e .stderr } "
32+ )
2533
2634
2735def test_demo_project_nox_pre_commit (robust_demo : Path ) -> None :
You can’t perform that action at this time.
0 commit comments