pypy/interpreter/test/test_app_main.py::TestNonInteractive::()::test_option_S_copyright
self = <pypy.interpreter.test.test_app_main.TestNonInteractive instance at 0x1b2d0328>
def test_option_S_copyright(self):
> data = self.run('-S -i', expect_prompt=True, expect_banner=True)
interpreter/test/test_app_main.py:994:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
interpreter/test/test_app_main.py:810: in run
data, status = self.run_with_status_code(*args, **kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <pypy.interpreter.test.test_app_main.TestNonInteractive instance at 0x1b2d0328>
cmdline = '/usr/local/bin/python3.12 "/buildbot/slave/own-linux-x86-32/build/pypy/interpreter/app_main.py" -S -i'
senddata = '', expect_prompt = True, expect_banner = True, python_flags = ''
env = None
def run_with_status_code(self, cmdline, senddata='', expect_prompt=False,
expect_banner=False, python_flags='', env=None):
if os.name == 'nt':
try:
import __pypy__
except:
py.test.skip('app_main cannot run on non-pypy for windows')
cmdline = '%s %s "%s" %s %s' % (get_python3(), python_flags,
app_main, python_flags, cmdline)
print('POPEN:', cmdline)
process = subprocess.Popen(
cmdline,
stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.STDOUT,
shell=True, env=env,
universal_newlines=True
)
child_in, child_out_err = process.stdin, process.stdout
child_in.write(senddata)
child_in.close()
data = child_out_err.read()
child_out_err.close()
process.wait()
assert (banner in data) == expect_banner # no banner unless expected
> assert ('>>>> ' in data) == expect_prompt # no prompt unless expected
E assert '>>>> ' in 'Python 3.12.13 (main, May 13 2026, 03:52:15) [Clang 22.1.5 ] on linux\nTraceback (most recent call last):\n File "/b...dtuple\n exec(code, namespace)\n File "<string>", line 1, in <module>\nNameError: name \'object\' is not defined\n' == True
interpreter/test/test_app_main.py:805: AssertionError
---------- Captured stdout call ----------
POPEN: /usr/local/bin/python3.12 "/buildbot/slave/own-linux-x86-32/build/pypy/interpreter/app_main.py" -S -i
builder: own-linux-x86-32 build #9546+
test: pypy/interpreter/test/test_app_main.py::TestNonInteractive::()::test_option_S_copyright