@@ -1867,6 +1867,7 @@ def check_killed(self, returncode):
18671867 else :
18681868 self .assertEqual (- signal .SIGKILL , returncode )
18691869
1870+ @support .requires_subprocess ()
18701871 def test_subprocess_exec (self ):
18711872 prog = os .path .join (os .path .dirname (__file__ ), 'echo.py' )
18721873
@@ -1888,6 +1889,7 @@ def test_subprocess_exec(self):
18881889 self .check_killed (proto .returncode )
18891890 self .assertEqual (b'Python The Winner' , proto .data [1 ])
18901891
1892+ @support .requires_subprocess ()
18911893 def test_subprocess_interactive (self ):
18921894 prog = os .path .join (os .path .dirname (__file__ ), 'echo.py' )
18931895
@@ -1915,6 +1917,7 @@ def test_subprocess_interactive(self):
19151917 self .loop .run_until_complete (proto .completed )
19161918 self .check_killed (proto .returncode )
19171919
1920+ @support .requires_subprocess ()
19181921 def test_subprocess_shell (self ):
19191922 connect = self .loop .subprocess_shell (
19201923 functools .partial (MySubprocessProtocol , self .loop ),
@@ -1931,6 +1934,7 @@ def test_subprocess_shell(self):
19311934 self .assertEqual (proto .data [2 ], b'' )
19321935 transp .close ()
19331936
1937+ @support .requires_subprocess ()
19341938 def test_subprocess_exitcode (self ):
19351939 connect = self .loop .subprocess_shell (
19361940 functools .partial (MySubprocessProtocol , self .loop ),
@@ -1942,6 +1946,7 @@ def test_subprocess_exitcode(self):
19421946 self .assertEqual (7 , proto .returncode )
19431947 transp .close ()
19441948
1949+ @support .requires_subprocess ()
19451950 def test_subprocess_close_after_finish (self ):
19461951 connect = self .loop .subprocess_shell (
19471952 functools .partial (MySubprocessProtocol , self .loop ),
@@ -1956,6 +1961,7 @@ def test_subprocess_close_after_finish(self):
19561961 self .assertEqual (7 , proto .returncode )
19571962 self .assertIsNone (transp .close ())
19581963
1964+ @support .requires_subprocess ()
19591965 def test_subprocess_kill (self ):
19601966 prog = os .path .join (os .path .dirname (__file__ ), 'echo.py' )
19611967
@@ -1972,6 +1978,7 @@ def test_subprocess_kill(self):
19721978 self .check_killed (proto .returncode )
19731979 transp .close ()
19741980
1981+ @support .requires_subprocess ()
19751982 def test_subprocess_terminate (self ):
19761983 prog = os .path .join (os .path .dirname (__file__ ), 'echo.py' )
19771984
@@ -1989,6 +1996,7 @@ def test_subprocess_terminate(self):
19891996 transp .close ()
19901997
19911998 @unittest .skipIf (sys .platform == 'win32' , "Don't have SIGHUP" )
1999+ @support .requires_subprocess ()
19922000 def test_subprocess_send_signal (self ):
19932001 # bpo-31034: Make sure that we get the default signal handler (killing
19942002 # the process). The parent process may have decided to ignore SIGHUP,
@@ -2013,6 +2021,7 @@ def test_subprocess_send_signal(self):
20132021 finally :
20142022 signal .signal (signal .SIGHUP , old_handler )
20152023
2024+ @support .requires_subprocess ()
20162025 def test_subprocess_stderr (self ):
20172026 prog = os .path .join (os .path .dirname (__file__ ), 'echo2.py' )
20182027
@@ -2034,6 +2043,7 @@ def test_subprocess_stderr(self):
20342043 self .assertTrue (proto .data [2 ].startswith (b'ERR:test' ), proto .data [2 ])
20352044 self .assertEqual (0 , proto .returncode )
20362045
2046+ @support .requires_subprocess ()
20372047 def test_subprocess_stderr_redirect_to_stdout (self ):
20382048 prog = os .path .join (os .path .dirname (__file__ ), 'echo2.py' )
20392049
@@ -2059,6 +2069,7 @@ def test_subprocess_stderr_redirect_to_stdout(self):
20592069 transp .close ()
20602070 self .assertEqual (0 , proto .returncode )
20612071
2072+ @support .requires_subprocess ()
20622073 def test_subprocess_close_client_stream (self ):
20632074 prog = os .path .join (os .path .dirname (__file__ ), 'echo3.py' )
20642075
@@ -2093,6 +2104,7 @@ def test_subprocess_close_client_stream(self):
20932104 self .loop .run_until_complete (proto .completed )
20942105 self .check_killed (proto .returncode )
20952106
2107+ @support .requires_subprocess ()
20962108 def test_subprocess_wait_no_same_group (self ):
20972109 # start the new process in a new session
20982110 connect = self .loop .subprocess_shell (
@@ -2105,6 +2117,7 @@ def test_subprocess_wait_no_same_group(self):
21052117 self .assertEqual (7 , proto .returncode )
21062118 transp .close ()
21072119
2120+ @support .requires_subprocess ()
21082121 def test_subprocess_exec_invalid_args (self ):
21092122 async def connect (** kwds ):
21102123 await self .loop .subprocess_exec (
@@ -2118,6 +2131,7 @@ async def connect(**kwds):
21182131 with self .assertRaises (ValueError ):
21192132 self .loop .run_until_complete (connect (shell = True ))
21202133
2134+ @support .requires_subprocess ()
21212135 def test_subprocess_shell_invalid_args (self ):
21222136
21232137 async def connect (cmd = None , ** kwds ):
0 commit comments