Your IP : 52.15.190.187
3
� f�$ � @ s� d Z ddlmZ ddlZddlmZ ddlmZ ddlZG dd� dej�Z G dd � d e
�ZG d
d� d�ZG dd
� d
ej�Z
G dd� dej�Zedkr�ejdd� dS )zTest run, coverage 42%.� )�runN)�mock)�captured_stderrc @ s e Zd Zdd� ZdS )�RunTestc C s� G dd� dt �}|d�}|d�}y
||�W np |k
r� y|�W nR |k
r� t� �2}tjjtd��}dd� |_tj� W d Q R X W d Q R X Y nX Y nX |j� j � j
� }| jdt|�� | j
d |d
� | j
d|d � d S )
Nc @ s e Zd Zdd� ZdS )zDRunTest.test_print_exception_unhashable.<locals>.UnhashableExceptionc S s dS )NT� )�self�otherr r �?/opt/alt/python36/lib64/python3.6/idlelib/idle_test/test_run.py�__eq__ s zKRunTest.test_print_exception_unhashable.<locals>.UnhashableException.__eq__N)�__name__�
__module__�__qualname__r
r r r r �UnhashableException
s r �ex1�ex2Zcleanup_tracebackc S s | S )Nr )�t�er r r �<lambda> s z9RunTest.test_print_exception_unhashable.<locals>.<lambda>� zUnhashableException: ex2� zUnhashableException: ex1�
)� Exceptionr r Zpatch�objectr Zside_effect�print_exception�getvalue�strip�
splitlines�assertEqual�lenZassertIn)r r r r �outputZct�tbr r r �test_print_exception_unhashable s$
(z'RunTest.test_print_exception_unhashableN)r r r
r! r r r r r
s r c @ s<