HEX
Server: Apache
System: Linux zacp120.webway.host 4.18.0-553.50.1.lve.el8.x86_64 #1 SMP Thu Apr 17 19:10:24 UTC 2025 x86_64
User: govancoz (1003)
PHP: 8.3.26
Disabled: exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname
Upload Files
File: //usr/local/lib/python3.7/test/__pycache__/test_repl.cpython-37.opt-1.pyc
B

��g��@s�dZddlZddlZddlZddlZddlmZddlmZm	Z	ddl
mZejej
d�dd�ZGd	d
�d
ej�Zedkr�e��dS)z!Test the interactive interpreter.�N)�dedent)�cpython_only�SuppressCrashReport)�kill_python)�stdout�stderrcOsftj�tj�tj�d�}|ddg}|�|�|�dttj	��}d|d<t
j|ftjt
j||d�|��S)z�Run the Python REPL with the given arguments.

    kw is extra keyword args to pass to subprocess.Popen. Returns a Popen
    object.
    z<stdin>z-Ez-i�envZvt100ZTERM)�
executable�stdinrr)
�os�path�join�dirname�sysr	�extend�
setdefault�dict�environ�
subprocess�Popen�PIPE)rr�args�kwZstdin_fnameZcmd_liner�r�*/usr/local/lib/python3.7/test/test_repl.py�
spawn_repls


rc@seZdZedd��ZdS)�TestInteractiveInterpreterc	Cs^d}t|�}|��}t�}t��|j�|�WdQRXt|�}|�d|�|�|jd�dS)Nz�
            import sys, _testcapi
            1/0
            print('After the exception.')
            _testcapi.set_nomemory(0)
            sys.exit(0)
        sAfter the exception.)��x)	r�encoderrr
�writerZassertIn�
returncode)�selfZ
user_input�p�outputrrr�test_no_memory'sz)TestInteractiveInterpreter.test_no_memoryN)�__name__�
__module__�__qualname__rr%rrrrr%sr�__main__)�__doc__rrZunittestr�textwraprZtest.supportrrZtest.support.script_helperrrZSTDOUTrZTestCaserr&�mainrrrr�<module>s