B � f{�@sldZddlmZddlZddlmZddlmZGdd�dej�Z Gdd �d ej�Z e d krhej d d �dS) zTest pyshell, coverage 12%.�)�pyshellN)�requires)�Tkc@seZdZdd�Zdd�ZdS)� FunctionTestc Cs�|j}xxdD]p\}}}d}|d}|j||d��F|p8d}t�||�}|t|�|�||||�d|�d|���WdQRXq WdS)N))��r)Zfiname��=�<r )�file�barZShellz RESTART: � )� assertEqual�subTestr� restart_line�len)�self�eqr �mulZextra�widthr �line�r�C/opt/alt/python37/lib64/python3.7/idlelib/idle_test/test_pyshell.py�test_restart_line_wide s z#FunctionTest.test_restart_line_widec Cspd\}}xF|d||dfD]0}|j|d��|�t�|d�|�WdQRXqW|�t�|dd�|d�dS)N)z= RESTART: Shell��)rr�z =)rrrr)rZexpectZtaglenrrrr�test_restart_line_narrows "z%FunctionTest.test_restart_line_narrowN)�__name__� __module__� __qualname__rrrrrrr s rc@s,eZdZedd��Zedd��Zdd�ZdS)�PyShellFileListTestcCstd�t�|_|j��dS)NZgui)rr�rootZwithdraw)�clsrrr� setUpClass"szPyShellFileListTest.setUpClasscCs|j��|`dS)N)r"Zdestroy)r#rrr� tearDownClass(s z!PyShellFileListTest.tearDownClasscCs,t�|j�}|�|jtj�|�|j�dS)N)rZPyShellFileListr"rZ EditorWindowZPyShellEditorWindowZ assertIsNone)rZpsflrrr� test_init0s zPyShellFileListTest.test_initN)rrr � classmethodr$r%r&rrrrr! s  r!�__main__r)� verbosity) �__doc__ZidlelibrZunittestZ test.supportrZtkinterrZTestCaserr!r�mainrrrr�s