JFIFxxC      C  " }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3RbrJFIFxxC      C  " }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3Rbr e f@sdZddlZddlmZddlmZmZddlmZGdddZ Gdd d ej Z e d krej d d ndS) z!Unit tests for idlelib.AutoExpandN)requires)TextTk) AutoExpandc@seZdZddZdS) Dummy_EditwincCs ||_dS)N)text)selfrr F/opt/alt/python34/lib64/python3.4/idlelib/idle_test/test_autoexpand.py__init__ szDummy_Editwin.__init__N)__name__ __module__ __qualname__r r r r r r s rc@s|eZdZeddZeddZddZddZd d Zd d Z d dZ ddZ dS)AutoExpandTestcCsedttkr=tdt|_t|j|_n t|_tt|j|_dS)NtkinterZgui) strrrrtkrrr auto_expand)clsr r r setUpClasss    zAutoExpandTest.setUpClasscCs5t|dr%|jj|`n|`|`dS)Nr)hasattrrZdestroyrr)rr r r tearDownClasss  zAutoExpandTest.tearDownClasscCs|jjdddS)Nz1.0end)rdelete)rr r r tearDown!szAutoExpandTest.tearDowncCs|j}|jj}|j}||d|jdd||d|jdd||d|jdd||d|jdd||d|jdd||d |jd d||d|jd d ||ddS) NinserttZhisthis isz sample stringstringz3.0z1.0r)rr getprevword assertEqualrr)rrpreviousequalr r r test_get_prevword$s$   z AutoExpandTest.test_get_prevwordcCs|jj}|jj}|j}|jjdd||jjddddg|d||d|d||d|d||d|d||ddS)Nrzab ac bx ad ab aabadacaevent)rr"expand_word_eventr#rrgetwords)rr$expandr%r r r test_before_only@s   "    zAutoExpandTest.test_before_onlycCs|j}|jj}|jj}|j}|jdd|jdd||jjddddg|d||d|d||d|d||d|d||ddS) Nrz a, [ab] ac: () bx"" cd ac= ad yaz1.1r'r)r(r*r+)rrr"r,r#rmark_setr-)rrr$r.r%r r r test_after_onlyPs    "    zAutoExpandTest.test_after_onlycCs|j}|jj}|jj}|j}|jdd|jdd|jdd||jjdddg|d||d|d||d|d||ddS) Nrz ab xy yz z a ac by acz2.1r'r)r*r+)rrr"r,r#rr0r-)rrr$r.r%r r r test_both_before_aftercs       z%AutoExpandTest.test_both_before_aftercCs|j}|jj}|j}||jjg||dd|jdd||jjg|jdd|jdd|d|jj}|jdd|d|jj}|j||dS)Nr+breakrz bx cy dz azac xy a ac ad az1.7z1.end) rrr,r#r-rr0stateZassertNotEqual)rrr.r%Z initial_stateZ new_stater r r test_other_expand_casesus       z&AutoExpandTest.test_other_expand_casesN) r r r classmethodrrrr&r/r1r2r5r r r r rs       r__main__ verbosity)__doc__ZunittestZ test.supportrrrrZidlelib.AutoExpandrrZTestCaserr mainr r r r s ~