Skip to content

Commit bd30460

Browse files
Polishing.
1 parent 90776ac commit bd30460

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

Lib/test/test_sys.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1976,7 +1976,9 @@ class TestRemoteExec(unittest.TestCase):
19761976
def tearDown(self):
19771977
test.support.reap_children()
19781978

1979-
def _run_remote_exec_test(self, script_code, python_args=None, env=None, prologue='', script_path=os_helper.TESTFN + '_remote.py'):
1979+
def _run_remote_exec_test(self, script_code, python_args=None, env=None,
1980+
prologue='',
1981+
script_path=os_helper.TESTFN + '_remote.py'):
19801982
# Create the script that will be remotely executed
19811983
self.addCleanup(os_helper.unlink, script_path)
19821984

@@ -2072,18 +2074,14 @@ def _run_remote_exec_test(self, script_code, python_args=None, env=None, prologu
20722074

20732075
def test_remote_exec(self):
20742076
"""Test basic remote exec functionality"""
2075-
script = '''
2076-
print("Remote script executed successfully!")
2077-
'''
2077+
script = 'print("Remote script executed successfully!")'
20782078
returncode, stdout, stderr = self._run_remote_exec_test(script)
20792079
# self.assertEqual(returncode, 0)
20802080
self.assertIn(b"Remote script executed successfully!", stdout)
20812081
self.assertEqual(stderr, b"")
20822082

20832083
def test_remote_exec_bytes(self):
2084-
script = '''
2085-
print("Remote script executed successfully!")
2086-
'''
2084+
script = 'print("Remote script executed successfully!")'
20872085
script_path = os.fsencode(os_helper.TESTFN) + b'_bytes_remote.py'
20882086
returncode, stdout, stderr = self._run_remote_exec_test(script,
20892087
script_path=script_path)

0 commit comments

Comments
 (0)