관리-도구
편집 파일: test_searchdialog.cpython-35.opt-1.pyc
��Yfk � @ s� d Z d d l m Z e d � d d l Z d d l Z d d l m Z d d l j Z d d l j Z Gd d � d e j � Z e d k r� e j d d d d � d S)z,Test SearchDialog class in SearchDialogue.py� )�requiresZguiN)� BooleanVarc @ sX e Z d Z e d d � � Z e d d � � Z d d � Z d d � Z d d � Z d S)�SearchDialogTestc C s t j � | _ d S)N)�tkZTk�root)�cls� r �H/opt/alt/python35/lib64/python3.5/idlelib/idle_test/test_searchdialog.py� setUpClass s zSearchDialogTest.setUpClassc C s | j j � | ` d S)N)r Zdestroy)r r r r � tearDownClass s zSearchDialogTest.tearDownClassc C s\ t j | j � | _ t j | j | j � | _ t j | j � | _ | j j d d � d S)Nz1.0zHello World!)�se�SearchEnginer �engine�sd�SearchDialog�dialogr ZText�text�insert)�selfr r r �setUp s zSearchDialogTest.setUpc C s | j } | j j d � | j | j j | � � | j j d � | j | j j | � � | j j d � | j | j j | � � | j j d � | j | j j | � � | j j d � | j | j j | � � t | j d � | j _ | j j d � | j | j j | � � d S)N� ZHelloZGoodbyezWorld!zHello World!Tz W[aeiouy]r) r r ZsetpatZassertFalser Z find_again� assertTruer r Zrevar)r r r r r �test_find_again# s z SearchDialogTest.test_find_againc C s� | j } | j j d d � | j d d d � | j | j j | � � | j d d d � | j d d d � | j | j j | � � | j d d d � | j d d d � | j | j j | � � | j d d � d S) Nz2.0zHello World!Zselz1.0z1.4�endz1.6z1.11)r r Ztag_addr r Zfind_selectionZ tag_removeZdelete)r r r r r �test_find_selection; s z$SearchDialogTest.test_find_selectionN) �__name__� __module__�__qualname__�classmethodr r r r r r r r r r s r �__main__� verbosity� �exit)�__doc__Ztest.supportr ZunittestZtkinterr r Zidlelib.SearchEnginer r Zidlelib.SearchDialogr r ZTestCaser r �mainr r r r �<module> s =