@@ -1815,6 +1815,7 @@ def check_killed(self, returncode):
18151815 else :
18161816 self .assertEqual (- signal .SIGKILL , returncode )
18171817
1818+ @support .requires_subprocess ()
18181819 def test_subprocess_exec (self ):
18191820 prog = os .path .join (os .path .dirname (__file__ ), 'echo.py' )
18201821
@@ -1836,6 +1837,7 @@ def test_subprocess_exec(self):
18361837 self .check_killed (proto .returncode )
18371838 self .assertEqual (b'Python The Winner' , proto .data [1 ])
18381839
1840+ @support .requires_subprocess ()
18391841 def test_subprocess_interactive (self ):
18401842 prog = os .path .join (os .path .dirname (__file__ ), 'echo.py' )
18411843
@@ -1863,6 +1865,7 @@ def test_subprocess_interactive(self):
18631865 self .loop .run_until_complete (proto .completed )
18641866 self .check_killed (proto .returncode )
18651867
1868+ @support .requires_subprocess ()
18661869 def test_subprocess_shell (self ):
18671870 connect = self .loop .subprocess_shell (
18681871 functools .partial (MySubprocessProtocol , self .loop ),
@@ -1879,6 +1882,7 @@ def test_subprocess_shell(self):
18791882 self .assertEqual (proto .data [2 ], b'' )
18801883 transp .close ()
18811884
1885+ @support .requires_subprocess ()
18821886 def test_subprocess_exitcode (self ):
18831887 connect = self .loop .subprocess_shell (
18841888 functools .partial (MySubprocessProtocol , self .loop ),
@@ -1890,6 +1894,7 @@ def test_subprocess_exitcode(self):
18901894 self .assertEqual (7 , proto .returncode )
18911895 transp .close ()
18921896
1897+ @support .requires_subprocess ()
18931898 def test_subprocess_close_after_finish (self ):
18941899 connect = self .loop .subprocess_shell (
18951900 functools .partial (MySubprocessProtocol , self .loop ),
@@ -1904,6 +1909,7 @@ def test_subprocess_close_after_finish(self):
19041909 self .assertEqual (7 , proto .returncode )
19051910 self .assertIsNone (transp .close ())
19061911
1912+ @support .requires_subprocess ()
19071913 def test_subprocess_kill (self ):
19081914 prog = os .path .join (os .path .dirname (__file__ ), 'echo.py' )
19091915
@@ -1920,6 +1926,7 @@ def test_subprocess_kill(self):
19201926 self .check_killed (proto .returncode )
19211927 transp .close ()
19221928
1929+ @support .requires_subprocess ()
19231930 def test_subprocess_terminate (self ):
19241931 prog = os .path .join (os .path .dirname (__file__ ), 'echo.py' )
19251932
@@ -1937,6 +1944,7 @@ def test_subprocess_terminate(self):
19371944 transp .close ()
19381945
19391946 @unittest .skipIf (sys .platform == 'win32' , "Don't have SIGHUP" )
1947+ @support .requires_subprocess ()
19401948 def test_subprocess_send_signal (self ):
19411949 # bpo-31034: Make sure that we get the default signal handler (killing
19421950 # the process). The parent process may have decided to ignore SIGHUP,
@@ -1961,6 +1969,7 @@ def test_subprocess_send_signal(self):
19611969 finally :
19621970 signal .signal (signal .SIGHUP , old_handler )
19631971
1972+ @support .requires_subprocess ()
19641973 def test_subprocess_stderr (self ):
19651974 prog = os .path .join (os .path .dirname (__file__ ), 'echo2.py' )
19661975
@@ -1982,6 +1991,7 @@ def test_subprocess_stderr(self):
19821991 self .assertTrue (proto .data [2 ].startswith (b'ERR:test' ), proto .data [2 ])
19831992 self .assertEqual (0 , proto .returncode )
19841993
1994+ @support .requires_subprocess ()
19851995 def test_subprocess_stderr_redirect_to_stdout (self ):
19861996 prog = os .path .join (os .path .dirname (__file__ ), 'echo2.py' )
19871997
@@ -2007,6 +2017,7 @@ def test_subprocess_stderr_redirect_to_stdout(self):
20072017 transp .close ()
20082018 self .assertEqual (0 , proto .returncode )
20092019
2020+ @support .requires_subprocess ()
20102021 def test_subprocess_close_client_stream (self ):
20112022 prog = os .path .join (os .path .dirname (__file__ ), 'echo3.py' )
20122023
@@ -2041,6 +2052,7 @@ def test_subprocess_close_client_stream(self):
20412052 self .loop .run_until_complete (proto .completed )
20422053 self .check_killed (proto .returncode )
20432054
2055+ @support .requires_subprocess ()
20442056 def test_subprocess_wait_no_same_group (self ):
20452057 # start the new process in a new session
20462058 connect = self .loop .subprocess_shell (
@@ -2053,6 +2065,7 @@ def test_subprocess_wait_no_same_group(self):
20532065 self .assertEqual (7 , proto .returncode )
20542066 transp .close ()
20552067
2068+ @support .requires_subprocess ()
20562069 def test_subprocess_exec_invalid_args (self ):
20572070 async def connect (** kwds ):
20582071 await self .loop .subprocess_exec (
@@ -2066,6 +2079,7 @@ async def connect(**kwds):
20662079 with self .assertRaises (ValueError ):
20672080 self .loop .run_until_complete (connect (shell = True ))
20682081
2082+ @support .requires_subprocess ()
20692083 def test_subprocess_shell_invalid_args (self ):
20702084
20712085 async def connect (cmd = None , ** kwds ):
0 commit comments