@,bif Sr/SQrSSKrSSKrSSKrSSKrSSKrSSKrSSKrSSK r SSK r SSK r SSK r SSK JrJr SSKJr SSKrSSKJrJr "SS\"SS 55r0rS r\"S 5r\"S 5r\"S 5r\"S5r\"S5r\"S5r\\-\-\-\-\-r\"S5r\"S5r \"S5r!\"S5r"\"S5r#\\ -\!-\"-\#-r$Sr%Sr&Sr'S[Sjr(Sr)Sr*S\Sjr+Sr,"SS\5r-S r.S!r/S"r0"S#S$\Rb5r2S%r3"S&S'5r4"S(S)5r5"S*S+5r6"S,S-5r7"S.S/5r8S0\9\:-S1\;4S2jr<"S3S45r="S5S6\>5r?"S7S8\>5r@"S9S:\85rASqBS]S=jrCS;SSSSS;SSS<\6"5S4 S>jrDS^S?jrESqFS@rG"SASB\ R5rI"SCSD\I5rJ"SESF\ R5rLS_SGjrM"SHSI\I5rNS;SS\6"5S4SJjrOSKrPSLrQSMrRS`SNjrSS`SOjrTSaSPjrU"SQSR5rV\VSSSTSUSVSWSX.rWSYrX\YSZ:Xa\ R"\X"55 gg)bzreStructuredText en)!register_optionflagDONT_ACCEPT_TRUE_FOR_1DONT_ACCEPT_BLANKLINENORMALIZE_WHITESPACEELLIPSISSKIPIGNORE_EXCEPTION_DETAILCOMPARISON_FLAGS REPORT_UDIFF REPORT_CDIFF REPORT_NDIFFREPORT_ONLY_FIRST_FAILUREREPORTING_FLAGS FAIL_FASTExampleDocTest DocTestParser DocTestFinder DocTestRunner OutputCheckerDocTestFailureUnexpectedException DebugRunnertestmodtestfilerun_docstring_examples DocTestSuite DocFileSuiteset_unittest_reportflagsscript_from_examples testsource debug_srcdebugN)StringIOIncrementalNewlineDecoder) namedtuple) ANSIColors can_colorizec<^\rSrSrSS.U4SjjrU4SjrSrU=r$) TestResultspr#skippedc4>[TU]XU5nX4lU$N)super__new__r-)clsfailed attemptedr-results __class__s ./opt/alt/python313/lib64/python3.13/doctest.pyr1TestResults.__new__qs'/#y9!c>UR(a*SURSURSURS3$[TU]5$)NzTestResults(failed=z , attempted=z , skipped=))r-r3r4r0__repr__)selfr6s r7r<TestResults.__repr__vsN <<)$++7!!% 01#||nA/ 0 7#% %r9)__name__ __module__ __qualname____firstlineno__r1r<__static_attributes__ __classcell__)r6s@r7r*r*ps34 &&r9r*zfailed attemptedcN[RUS[[5-5$)N)OPTIONFLAGS_BY_NAME setdefaultlen)names r7rrs  ) )$S9L5M0M NNr9rrrrrrr r r r rz z...cSn[RH8nURUS5nU[[U5LdM*XR-nM: U$Nr#) __future__all_feature_namesgetgetattr compiler_flag)globsflagsfnamefeatures r7_extract_future_flagsrWsM E--))E4( gj%0 0 ** *E. Lr9c[R"U5(aU$[U[5(a[ U[ 5[ 5S/5$Uc)[R[R"U5$[S5e![a7 [R[R"U5RSs$f=f![a gf=f)N*r@z"Expected a module, string, or None)inspectismodule isinstancestr __import__globalslocalssysmodules_getframemodulenameAttributeError _getframe f_globalsKeyError TypeError)moduledepths r7_normalize_modulerks FC &')VXu==   O{{3#:#:5#ABB <== " O{{3==#7#A#A*#MNN O   s*&B >C C C  C CCc:[SS5RUS5$NT)r%decode)datas r7_newline_convertrps $T4 0 7 7d CCr9cU(a~[US5n[X5n[USS5=ncURRn[ US5(a/URU5nURU5n[U5U4$[XS9nUR5U4sSSS5 $![ a Nqf=f!,(df  g=f)N __loader__get_data)encoding) rk_module_relative_pathrQ__spec__loaderrdhasattrrtrnrpopenread)filenamepackagemodule_relativerurx file_contentsfs r7_load_testfilers#GQ/(;g|T: :F C  ))00 6: & &"OOH5M)00:M$M2H< < h *avvx! + *"   + *sB+B;+ B87B8; C c8[R"SUS-U5$)Nz (?m)^(?!$) )resub)sindents r7_indentrs 66,s A ..r9cj[5nUup#n[R"X#XAS9 UR5$)N)file)r$ tracebackprint_exceptiongetvalue)exc_infoexcoutexc_typeexc_valexc_tbs r7_exception_tracebackr s2 ZF (Hv hE ?? r9c$\rSrSrSrSSjrSrg) _SpoofOuticv[R"U5nU(aURS5(dUS- nU$N )r$rendswith)r=results r7r_SpoofOut.getvalues3""4( &//$// dNF r9NcRURU5 [R"U5 gr/)seekr$truncate)r=sizes r7r_SpoofOut.truncate#s $$r9r?r/)r@rArBrCrrrDr?r9r7rrs  r9rc[U;aX:H$UR[5nS[U5pCUSnU(a&URU5(a[U5nUS OgUSnU(a)UR U5(aU[U5-nUS OgX4:agUH+nUR XSU5nUS:a gU[U5- nM- g)Nr#FT)ELLIPSIS_MARKERsplitrJ startswithrfind)wantgotwsstartposendposws r7_ellipsis_matchr(s d"{ O $B#c(f 1A >>!  1vH1 2A <<?? c!f F2 88A0 a<CF r9c<UR5nU(aSU-$g)Nz# #)rstrip)lines r7 _comment_linerYs ;;=D Dyr9cS[U5p!URS5nUS:aUnURSSU5nUS:aUnURSSU5nUS:aUS-nXU$)Nr#r:.rG)rJrrfind)msgstartendis r7_strip_exception_detailsrasrCH3 AAv aAAv #q#AAv! c?r9c0\rSrSrSrSSjrSrSrSrg) _OutputRedirectingPdbi{chXlSUl[RR XSS9 SUlg)NFT)stdoutnosigintrG)_OutputRedirectingPdb__out$_OutputRedirectingPdb__debugger_usedpdbPdb__init__ use_rawinput)r=outs r7r_OutputRedirectingPdb.__init__s. $ D9r9NcSUlUc[R"5Rn[R R X5 grm)rraref_backrr set_trace)r=frames r7r_OutputRedirectingPdb.set_traces2# =MMO**E $&r9cfUR(a [RRU5 ggr/)rrr set_continuer=s r7r"_OutputRedirectingPdb.set_continues$    GG  & r9c[RnUR[l[RR "U/UQ76U[l$!U[lf=fr/)rarrrrtrace_dispatch)r=args save_stdouts r7r$_OutputRedirectingPdb.trace_dispatchsAjj ZZ  %77))$66$CJCJs A A )__debugger_used__outrr/) r@rArBrCrrrrrDr?r9r7rr{s ' ' %r9rc[R"U5(d[SU-5eURS5(a [ S5e[ R R"URS56n[US5(a.[ R RUR5SnGO URS:Xay[[R5S:aK[RSS:wa4[ R R[RS5SnO[ RnO[US5(aZUR HJn[ R RX15n[ R R#U5(dMHUs $ [ S UR-5e[ R RX!5$) NzExpected a module: %r/z1Module-relative files may not have absolute paths__file__r#__main____path__zBCan't resolve paths relative to the module %r (it has no __file__))rZr[rhr ValueErrorospathjoinrryrr@rJraargvcurdirrexists)ri test_pathbasedir directoryfullpaths r7rvrvsT   F # #/&899C  LMM ys35Ivz""''--03 J & sxx=?sxx{b0ggmmCHHQK03GiiG 6: & &#__ 77<< =77>>(++#O- 3!??+, , 77<< ++r9c.\rSrSrSSjrSrSrSrg)riNc URS5(dUS- nU(aURS5(dUS- nUbURS5(dUS- nXlX lX@lXPlUc0nX`lX0lgr)rsourcerlinenoroptionsexc_msg)r=rrrrrrs r7rExample.__init__s|t$$ dNF  d++ DLD  w'7'7'='= tOG    ?bG  r9c[U5[U5La[$URUR:H=(a URUR:H=(ay URUR:H=(aY UR UR :H=(a9 UR UR :H=(a URUR:H$r/)typeNotImplementedrrrrrrr=others r7__eq__Example.__eq__s :T%[ (! !{{ell*-yyEJJ&-{{ell*-{{ell*-||u}}, - ||u}},  -r9c[URURURURUR 45$r/)hashrrrrrrs r7__hash__Example.__hash__s3T[[$))T[[$++\\#$ $r9)rrrrrr)Nr#r#N)r@rArBrCrrrrDr?r9r7rrsFEF$ -$r9rc2\rSrSrSrSrSrSrSrSr g) ricjXlX`lUR5UlX0lX@lXPlgr/)examples docstringcopyrSrKr|r)r=rrSrKr|rrs r7rDocTest.__init__*s*! "ZZ\    r9c 4[UR5S:XaSnO4[UR5S:XaSnOS[UR5-nSURR<SUR<SUR <S UR <S U<S 3 $) Nr#z no examplesrGz 1 examplez %d examples)rJrr6r@rKr|r)r=rs r7r<DocTest.__repr__8sp t}}  "$H  1 $"H$s4=='99H((DMM4;;B Cr9c[U5[U5La[$URUR:H=(a URUR:H=(ay URUR:H=(aY UR UR :H=(a9 UR UR :H=(a URUR:H$r/)rrrrrSrKr|rrs r7rDocTest.__eq__Cs :T%[ (! !}}.+~~0+zzU[[(+yyEJJ&+}}. + {{ell*  +r9cp[URURURUR45$r/)rrrKr|rrs r7rDocTest.__hash__Ns&T^^TYY t{{KLLr9c2[U[5(d[$URb UROSnURb UROSnURUR U[ U54URUR U[ U54:$)Nr)r\rrrrKr|id)r=rself_lno other_lnos r7__lt__DocTest.__lt__Rsy%))! !"&++"94;;r$)LL$U^^Y5 BC Dr9)rrr|rSrrKN) r@rArBrCrr<rrrrDr?r9r7rrs0  C +MDr9rc\rSrSr\R "S\R \R-5r\R "S\R\R -\R-5r \R "S5Rr SSjr SrSSjrSr\R "S \R 5rS r\R "S \R 5rS rS rSrSrg)ri_a # Source consists of a PS1 line followed by zero or more PS2 lines. (?P (?:^(?P [ ]*) >>> .*) # PS1 line (?:\n [ ]* \.\.\. .*)*) # PS2 lines \n? # Want consists of any non-blank lines that do not start with PS1. (?P (?:(?![ ]*$) # Not a blank line (?![ ]*>>>) # Not a line starting with PS1 .+$\n? # But any other line )*) a # Grab the traceback header. Different versions of Python have # said different things on the first traceback line. ^(?P Traceback\ \( (?: most\ recent\ call\ last | innermost\ last ) \) : ) \s* $ # toss trailing whitespace on the header. (?P .*?) # don't blink: absorb stuff until... ^ (?P \w+ .*) # a line *starts* with alphanum. z ^[ ]*(#.*)?$cUR5nURU5nUS:a3SRURS5Vs/sHoDUSPM sn5n/nSupgURR U5HnUR XUR55 XqRSXhR55- nURXU5uppURU 5(d7UR [XU UU[URS55-U S95 XqRSUR5UR55- nUR5nM UR XS5 U$s snf)Nr#r)r#r#r)rrr) expandtabs _min_indentrr _EXAMPLE_REfinditerappendrcount_parse_example_IS_BLANK_OR_COMMENTrrJgroupr) r=stringrK min_indentloutputcharnormrrrrs r7parseDocTestParser.parsesX""$%%f- >YY T8JK8J1*+8JKLF!!**62A MM& 2 3 ll4; ;F((&9 -Vd,,V44 wvW+1+5c!''(:K6L+L,3 57 ll4AEEG< c<[URX5UX4XQ5$r/)r get_examples)r=rrSrKr|rs r7 get_doctestDocTestParser.get_doctests%t((6v7 7r9c~URX5Vs/sHn[U[5(dMUPM sn$s snfr/)r!r\r)r=rrKxs r7r$DocTestParser.get_exampless< ::f3+3aa)3+ ++s::c [URS55nURS5RS5nURXTX#5 UR USSSU-S-X#5 SR UVs/sH ofUS-SPM sn5nURS5nURS5n [U 5S:a"[ R"S U S 5(aU S UR U SU-UU[U5-5 SR U V s/sHoUSPM sn 5nURRU5nU(aURS 5n OSn URXrU5n X|X4$s snfs sn f) NrrrrGrrrz *$rr) rJrr_check_prompt_blank _check_prefixrrmatch _EXCEPTION_RE _find_options) r=r rKrr source_linesslrr want_lineswlrrs r7rDocTestParser._parse_examplesjQWWX&'wwx(..t4    tD <+SZ#-=tLLALbvaxyMLAB wwvZZ% z?Q 288FJrN#C#C2 :s6z4!C $55 7yy ; "VW+ ;<    $ $T * ggenGG$$V6:--/B??+6!":6!'c!1 )< t0088$dF45 5r9z ^([ ]*)(?=\S)cURRU5Vs/sHn[U5PM nn[U5S:a [U5$gs snfrM) _INDENT_REfindallrJmin)r=rrindentss r7rDocTestParser._min_indent$sJ-1__-D-DQ-GH-G63v;-GH w "((1*d"&fQh"7"?@@(r9c [U5H@upVU(dMURU5(aM&[SXE-S-<SU<SU<35e g)Nr8rGrGz& has inconsistent leading whitespace: )rHrr)r=rIprefixrKrrrs r7r-DocTestParser._check_prefix:sG !'GAtDOOF33 "((1*dD":;;(r9r?N)z)r@rArBrCrcompile MULTILINEVERBOSErDOTALLr/r.rr!r%r$rr:r0rArr,r-rDr?r9r7rr_s**  \\BJJ & (K,JJ ZZ",, & 2 4M::o6<<%N 7 +*.f::&D&(ll48,bll;J @ ;r9rcX\rSrSrS\"5SS4SjrS SjrSrSrS r S r S r S r g)riJFTc4X lXlX0lX@lgr/)_parser_verbose_recurse_exclude_empty)r=verboseparserrecurse exclude_emptys r7rDocTestFinder.__init__Ss"   +r9Nc Uc([USS5nUc[S[U5<35eUSLaSnOUc[R"U5n[R "U5nU(d'[R "U5nUSUSS-S:XdSnUcSnOCUb![R"XcR5nO[R"U5nU(dSnUc!Uc0nO+URR5nOUR5nUbURU5 SU;aSUS'/nURXX#Xt05 UR5 U$![a SnNf=f)Nr@zHDocTestFinder.find: name must be given when obj.__name__ doesn't exist: Fr#z<]>r)rQrrrZ getmodule getsourcefilegetfile linecachegetlines__dict__rhrupdate_findsort) r=objrKrirS extraglobsrr1testss r7rDocTestFinder.findispH <3 D1D| "&s)".// U?F ^&&s+F  (((-Ds+AwtBCy(E1$4|# %$-#5#5dOO#LL$-#5#5d#;L##'L =~,,.JJLE  ! LL $ U " *E*  5t\"E   Y L sE E%$E%cUcg[R"U5bU[R"U5L$[R"U5(aURURL$[R "U5(d "U5(aV[US5(aURRnO[US5(a URnOgURU:H$[R"U5(aURUR:H$[US5(aURUR:H$[U[5(ag[S5e)NT __objclass__rAz"object must be a class or function)rZr_ isfunctionrd __globals__ismethoddescriptorismethodwrapperryrmrAr@isclassr\propertyr)r=riobjectobj_mods r7 _from_moduleDocTestFinder._from_modules% >   v & 2W..v66 6    ' '??f&8&88 8((00%%f--v~.. --88.. ++??g- - __V $ $??f&7&77 7 V\ * *??f&7&77 7  ) )AB Br9cUn[R"U5n[R"U5$![a N"f=fr/)rZunwrapr isroutine)r=rh maybe_routines r7 _is_routineDocTestFinder._is_routinesC  #NN=9M  //   s 0 ==c ^UR(a[SU-5 [U5U;agSU[U5'URX#XFU5nUbUR U5 [ R "U5(aUR(aURR5HmupU<SU <3n URU 5(d[ R"U 5(dMAURXJ5(dMYURXXUXg5 Mo [ R "U5(aUR(a[US05R5Hup[U [ 5(d[#S[%U 5<35e[ R&"U 5(dc[ R"U 5(dH[ R "U 5(d-[U [ 5(d[#S[%U 5<35eU<SU <3n URXXUXg5 M [ R"U5(aUR(aURR5Hup[U [([*45(a U R,n [ R&"U 5(d2[ R"U 5(d[U [.5(dMyURXJ5(dMU<SU <3n URXXUXg5 M ggg)NzFinding tests in %srGr__test__z3DocTestFinder.find: __test__ keys must be strings: z^DocTestFinder.find: __test__ values must be strings, functions, methods, classes, or modules: z .__test__.)rUprintr  _get_testrrZr[rVrditemsr|rrrvrfrQr\r]rrrz staticmethod classmethod__func__rs) r=rjrhrKrir1rSseentestvalnamevals r7rfDocTestFinder._findsh == '$. / c7d? RW ~~c E   LL    C T]] # 2 2 4 %)73%%c**gooc.B.B%%f22JJu7L$, !5   C T]] 'Z < B B D !'3//$&*7m&677 ))#..'//#2F2F((--C1E1E$'+3i&233/3G< 5w  (!E ??3  DMM # 2 2 4 cL+#>??,,C&&s++ws/C/C h//''44)-w7GJJu7L$,!5%2 r9c[U[5(aUnO=URcSnO,URn[U[5(d [U5nUR X5nUR (aU(dgUcSnO.[USS5=(d URnUSSS:XaUSSnURRXdUX5$![[4a SnNf=f)Nrr.pycr) r\r]__doc__rhrd _find_linenorWrQr@rTr%) r=rhrKrirSr1rrr|s r7rDocTestFinder._get_test4s c3  I ;;& "I # I%i55$' N ""35   y >Hvz48KFOOH}&#CR=||'' $(0: :%~.   sC,CC&%C&c Sn[USS5n[R"U5(aUbSn[R"U5(amUbjUcg[R "S[R "[USS55-5n[U5HupgURU5(dMUn O [R"U5(a URn[U[5(a URn[U[R5(a UR n[R""U5(a5[USS5(a#[R$"U5nUR&n[R*"U5(a UR,n[R."U5(a UR0n[R2"U5(aUR4S- nUbVUcUS-$[R "S5n[7U[9U55HnURX#5(dMUs $ g![(a gf=f)Nrr#z^\s*class\s*%s\br@-rGz(^|.*:)\s*\w*("|\'))rQrZr[rrrrNescaperHr.ismethodrr\rsfget functoolscached_propertyfuncrzry__code__rd istracebacktb_frameisframef_codeiscodeco_firstlinenorangerJ)r=rhr1rrpatrrs r7rDocTestFinder._find_linenoZs CD1    C Y%:F ??3  I$9#**0YYwsJ'DEFGC$\299T??F3   C  # c8 $ $((C c944 5 5((C   S ! !gc9d&C&C..%C ll   s # #3<>#  ''!+F  #ax**34CL(9:99\122!M; 1"   s/ I II)rWrTrVrUNNNN) r@rArBrCrrrrvr|rfrrrDr?r9r7rrJs8 %]_T,,dLC: 0;,z$:L=r9rc\rSrSrSrSSjrSrSrSrSr S r S r S r \ R"S 5rSS jrSSjrSSjrSrSrg)rizF**********************************************************************NcU=(d [5UlUcS[R;nX lX0lX0lSUlSUlSUl 0Ul [5Ul g)N-vr#) r_checkerrarrU optionflagsoriginal_optionflagstriesfailuresskips_statsr_fakeout)r=checkerrXrs r7rDocTestRunner.__init__s_" 2=? ?chh&G &$/!    "  r9cUR(akUR(a8U"S[UR5-S-[UR5-5 gU"S[UR5-S-5 gg)NzTrying: z Expecting: zExpecting nothing )rUrrr)r=rrexamples r7 report_startDocTestRunner.report_startsj ==||K''.."99"#%,W\\%:;<K''.."99)*+ r9c8UR(a U"S5 gg)Nzok )rUr=rrrrs r7report_successDocTestRunner.report_successs == K r9cU"URX#5URRX4UR5-5 gr/)_failure_headerroutput_differencerrs r7report_failureDocTestRunner.report_failures: D  / MM + +G$:J:J K L Mr9cbU"URX#5S-[[U55-5 g)NzException raised: )rrrr=rrrrs r7report_unexpected_exception)DocTestRunner.report_unexpected_exception s6 D  / ! "$+,@,J$K L Mr9cv[5(a [R[R4OSup4UURU3/nUR (akUR b*UR bUR UR -S-nOSnURSUR <SU<SUR<35 O0URSUR S-<SUR<35 URS5 URnUR[U55 S RU5$) N)rrrG?zFile "", line , in zLine zFailed example:r) r(r'REDRESETDIVIDERr|rrrKrrr)r=rrredresetrrrs r7rDocTestRunner._failure_header's2>..Z^^Z-- .h t||nUG,- =={{&7>>+Ew~~59 JJ vtyy: ; JJ7>>!+;TYYG H $% 76?#yy~r9c ^S=n=pVURn[S5upn URRn [ UR 5GHJupUS- nUR[ -=(a US:nXplU R(aXU RR5H:unnU(aU=RU-slM$U=RU)-slM< UR[-(aUS- nMU(dURX1U 5 SURU 4-n[[U RUSUS5UR5 UR R#5 SnUR*R-5nUR*R/S5 U nUc'U "U R0UUR5(aUnGO0[2R4"USS6n[7US[85(aWUSR:S3USR<S USR:S34m[?U4S j[ U555nUUSnS RAU5nU(dU[CU5- nU RDcU nOuU "U RDUUR5(aUnOOUR[F-(a7U "[IU RD5[IU5UR5(aUnUULaU(dURKX1U U5 OIUU La U(dURMX1U U5 US- nO$UU LaU(dUROX1U U5 US- nU(dGM0UR[P-(dGMK O XplURSXXV5 [UXEUS 9$![$a e [&R("5nUR R#5 GN=f) Nr#rrrGzsingleTrrc3\># UH!upURT5(dMUv M# g7fr/)r).0indexrexception_line_prefixess r7 &DocTestRunner.__run..s))+BKE??+BC+Bs, ,rr,)+rrr check_outputrHrr rrrrrKexecrNrrSdebuggerrKeyboardInterruptrarrrrrrformat_exception_only issubclass SyntaxErrorrBrAnextrrrrrrrrr_DocTestRunner__record_outcomer*)r=r compileflagsrrr4rrSUCCESSFAILUREBOOMcheck examplenumrquiet optionflagrr| exceptionroutcome formatted_ex exc_msg_indexrrs @r7__runDocTestRunner.__run>s()((9 $//!&q$ **$-T]]#; J NI%%(AA"\  4 )0)>)>)@%Z((J6(((ZK7( *A$& !!#W5 *TYY ,CCH -WW^^Xx)4126**> **, --((*C MM " "1 %G sD,<,<==%G )>> "1 N ilK88 %Q<445Q7$Q<2231Yq\5N5N4OqQ/+%))+4\+B)%M $0 #?L'',// ::C??*"G7??GT5E5EFF%G%%(??5gooF5g>!--//#*'!''7C@G#''7C@A D44S5>@A xD,,y88a$>_%  -LLN  **,s /A N==;O;cURRURS5upVnX%-X6-XG-4URUR'U=RU- slU=RU- slU=R U- slg)N)r#r#r#)rrPrKrrr)r=rrrr failures2tries2skips2s r7__record_outcomeDocTestRunner.__record_outcomesq %)KKOODIIy$I! 6"*"6"'."'."2 DII !  e  e r9z..+)\[(?P\d+)\]>$cNURRU5nU(asURS5URR:XaJURR [ URS55nURRSS9$URX5$)NrKrTkeepends) %_DocTestRunner__LINECACHE_FILENAME_REr.rrrKrintr splitlinessave_linecache_getlines)r=r|module_globalsr rs r7__patched_linecache_getlines*DocTestRunner.__patched_linecache_getliness}  ( ( . .x 8 DIINN2ii((QWW\-B)CDG>>,,d,; ;//I Ir9c^ ^XlUc[UR5n[RmUc7TR m T bT R 5S:Xa TRnOU U4SjnUR[l[R"5n[Rn[T5Ul URR5 URR[l [R UlUR$[l[R&n[R([l[*R,nS[*lSSS.n U H%n [.R0R3U S5X'M' UR5XU5T[lU[l [R6"U5 UR"[lU[lU[*lU R95HupU cM U [.R0U 'M U(a&URR;5 SSKn SU l$$!T[lU[l [R6"U5 UR"[lU[lU[*lU R95HupU cM U [.R0U 'M U(a&URR;5 SSKn SU lff=f)Nutf-8c`>[URTS5T5nTRU5 g)Nbackslashreplace)r]encodewrite)rrurs r7rDocTestRunner.run..outs)AHHX/ABHMA%%a(r9cgNFr?)rkwargss r7#DocTestRunner.run..sr9) PYTHON_COLORS FORCE_COLORr#) rrWrSrarrulowerrrgettracerrrrrrbrcr*_DocTestRunner__patched_linecache_getlines displayhook__displayhook__ _colorizer(renvironpop_DocTestRunner__runsettracerclearbuiltins_)r=rrr clear_globs save_tracesave_set_tracesave_displayhooksaved_can_colorizecolor_variableskeyvaluerrurs @@r7runDocTestRunner.runs>(  0>#3w#>!'')]] \\^ -k:   // (1'9'9$!>> ??--&33!> ,0F"C#%::>>#t#[[U5S35 UR5 UHn[SU35 M U(aS[U[U5SU35 [U5H)unnUS:XaSOSn[SUUS S US UU35 M+ U(a`[UUR U35 [[U5S 35 [U5Hunupn [SU S S U S S U35 M! U(a[US:XaSOSn[US US [UR5S35 U(a SUUSU3OSn[UXV- SUUS35 U(aDUS:XaSOSnUSUSUU3nU(aUS:XaSOSnUSUUSUU3n[US35 OU(a[U SU35 [#XeUS9$)Nr#z had no tests:z z passed all tests:rGrrr3dz testz in z had failures:z of rz and z failedz passedz***Test Failed*** z failurez skipped testz Test passed.r,)rUrrrr get_colors BOLD_GREENBOLD_REDGREENrrYELLOWr_n_itemsrgsortedrr*)r=rXnotestspassedr3 total_triestotal_failures total_skipsrKrrransi bold_greenbold_redgreenrryellowrrand_frs r7 summarizeDocTestRunner.summarize4s ?mmG"$b"566 6n.2kk.?.?.A *D*8E  K  &N  Kzt$Q tm, t%=>?/B##%__ == hh  '*+>:; #DD-($ 011CE7KL#)&>KD%#qjcAAeWU2JeA3d4&HI$2  SE$,,w/ 0 Xf%&n5 628...x(2d5*D?@3A !Q&CA [Mqcht{{.C-DAF G"u^,GE7;')  UGK89waP Q $)sAJ00@E7SC%*BU6(;-}QCwO SE)   ZL UG4 5> LLr9cURnURR5H'unupEnX2;aX#upxn XG-nXX-nXi-nXEU4X#'M) gr/)rr) r=rdrKrrrrrrs r7mergeDocTestRunner.merges` KK.3ll.@.@.B *D*8Ey,-G) 6#/.AG /Cr9) rrrrUrrrrrrrr)NNr#r/NNT)r@rArBrCrrrrrrrrrrrNrr rr5r9rDr?r9r7rrsi@G$J +MM.K?Z !jj*FGJL"bKM`/r9rrreturnc:[U5nUS:XaSOSnUSU3$)NrGrrz item)rJ)rnrs r7r(r(s* E A1f#ASaS>r9c,\rSrSrSrSrSrSrSrg)ric:[URSS5S5$)NASCIIr)r]r)r=rs r7_toAsciiOutputChecker._toAsciis188G%78'BBr9c0URU5nURU5nX!:XagU[-(dX!4S:XagX!4S:XagU[-(dQ[R"S[R "[ 5-SU5n[R"SSU5nX!:XagU[-(aDSRUR55nSRUR55nX!:XagU[-(a[X5(agg) NT)zTrue z1 )zFalse z0 z (?m)^%s\s*?$rz(?m)^[^\S\n]+$rF) rBrrrrrBLANKLINE_MARKERrrrrrr=rrrs r7rOutputChecker.check_outputs mmC }}T" ;44z..z//3366/BII6F,GGd$D&&*B4C{ - -((399;'C88DJJL)D{  !t))r9cU[[-[--(dgU[-(agURS5S:=(a URS5S:$)NFTrr)r r r rrFs r7_do_a_fancy_diffOutputChecker._do_a_fancy_diffsVl*+*+,  %zz$!#; $!(;;r9c*URnU[-(d[R"S[U5nUR XBU5(aUR SS9nUR SS9nU[-(a&[R"XVSS9n[U5SSnSnOU[-(a&[R"XVSS9n[U5SSnSnOLU[-(a>[R"[RS9n [U R!XV55nS nS W-[#S R%W55-$U(a#U(aS [#U5<S [#U5<3$U(aS[#U5-$U(aS[#U5-$g)Nz(?m)^[ ]*(?= )Trr)r>z#unified diff with -expected +actualz-context diff with expected followed by actual)charjunkzndiff with -expected +actualzDifferences (%s): rz Expected: zGot: zExpected: %sGot nothing zExpected nothing Got: %szExpected nothing Got nothing )rrrrrErIrr difflib unified_difflistr context_diffr DifferIS_CHARACTER_JUNKcomparerr) r=rrrrr3 got_linesdiffkindengines r7rOutputChecker.output_differencesQ||33&&*, >4r9r?N) r@rArBrCrBrrIrrDr?r9r7rrsC <~<.,5r9rc \rSrSrSrSrSrg)ri*c(XlX lX0lgr/)rrr)r=rrrs r7rDocTestFailure.__init__5s  r9c,[UR5$r/r]rrs r7__str__DocTestFailure.__str__:499~r9)rrrNr@rArBrCrr^rDr?r9r7rr*s  r9rc \rSrSrSrSrSrg)ri=c(XlX lX0lgr/)rrr)r=rrrs r7rUnexpectedException.__init__Hs   r9c,[UR5$r/r]rs r7r^UnexpectedException.__str__Mr`r9)rrrNrar?r9r7rr=s ! r9rc*\rSrSrSSjrSrSrSrg)riPNcv[RXX#S5nU(aURR5 U$r)rrrSr)r=rrrrrs r7rDebugRunner.runs.   d,U C  JJ   r9c[X#U5er/)rrs r7r'DebugRunner.report_unexpected_exceptions!$::r9c[X#U5er/)rrs r7rDebugRunner.report_failuresTC00r9r?r;)r@rArBrCrrrrDr?r9r7rrPsv ;1r9rTFc  Uc[RRS5n[R"U5(d[ SU<35eUc UR n[US9n U(a [X5S9n O [X5S9n U RXX&S9Hn U RU 5 M U(aU R5 [cU q O[RU 5 [U R U R"U R$S9$)Nrztestmod: module required; )r[rXrrSrir,)rarbrPrZr[rhr@rrrrrr5masterr9r*rrr) r rKrSrXreportrriraise_on_errorr[finderrunnerrs r7rrsJ y KKOOJ '   A  !=>> |zz 7FWFwH A5 H 4I ~ V v fll KKr9c LU(aU(d [S5e[XUU =(d S5upUc[RR U5nUc0nOUR 5nUbUR U5 SU;aSUS'U (a [XWS9n O [XWS9n U RXX S5nU RU5 U(aU R5 [cU q O[RU 5 [U RU R U R"S9$)N8Package may only be specified for module-relative paths.rr@rrpr#r,)rrrrbasenamerrerrr%rr5rrr9r*rrr)r|r~rKr}rSrXrsrrirtrYrutextrvrs r7rr)sd+, ,$H$,$79ND |ww) }  Z &jWFwH   d41 =D JJt  ~ V v fll KKr9cv[USS9n[X%S9nURXUS9HnURXS9 M g)NF)rXrZrp)rS)r)rrrr) rrSrXrKrrrurvrs r7rrs?$7E :F 7 DF A5 1 4 32r9cHU[-U:wa [SU5e[nUqU$)NzOnly reporting flags allowed)rr_unittest_reportflags)rTolds r7rrs/: E)7?? C! Jr9cv\rSrSrSSjrSrSrSrSrSr S r S r S r S r \RrS rSrg) DocTestCaseiNc~[RRU5 X lXPlXlX0lX@lgr/)unittestTestCaser_dt_optionflags _dt_checker_dt_test _dt_setUp _dt_tearDown)r=rrsetUptearDownrs r7rDocTestCase.__init__s4 ""4(*" $r9cURnURR5UlURbUR U5 ggr/)rrSr _dt_globsrr=rs r7rDocTestCase.setUps8}}* >> % NN4  &r9cURnURbURU5 URR5 URR UR 5 gr/)rrrSrrerrs r7rDocTestCase.tearDownsM}}    (   d #  $..)r9cURn[Rn[5nURnU[ -(d U[ -n[UURSS9nSUl URXRSS9nURUR:Xa[R"S5eU[lUR (a.UR#UR%UR'555eg!U[lf=f)NFrrrXzF----------------------------------------------------------------------)rrzall examples were skipped)rrarr$rrr}rrrrrr-r4rSkipTestr3failureExceptionformat_failurer)r=rr~newrrvr5s r7runTestDocTestCase.runTest s}}jjj** o- 0 0K;'+'7'7H #FNjj99%jHG'"3"33''(CDD4CJ >>''(;(;CLLN(KL L CJs AC== D c URnURcSnOSUR-nSRURR S5SS5nSUR<SUR <SU<SU<S U<3 $) Nzunknown line numberz%srrFailed doctest test for File "rrz )rrrrKrr|)r=errrrlnames r7rDocTestCase.format_failure sj}} ;; *FDKK'F-bc2399dmmVUCA r9cUR5 [URURSS9nUR UR SS9 UR 5 g)NFr)r)rrrrrrr)r=rvs r7r"DocTestCase.debug( sID )=)=%)%5%5uF 4==e 4 r9c.URR$r/rrKrs r7r DocTestCase.idp s}}!!!r9cn[U5[U5La[$URUR:H=(ay URUR:H=(aY URUR:H=(a9 UR UR :H=(a UR UR :H$r/)rrrrrrrrs r7rDocTestCase.__eq__s s :T%[ (! !}}.5##u'<'<<5~~05  E$6$6655#4#44  5r9cp[URURURUR45$r/)rrrrrrs r7rDocTestCase.__hash__} s3T))4>>4;L;L%%'( (r9cURRRS5nUS<SSRUSS5<S3$)Nrrrr;)rrKrr)r=rKs r7r<DocTestCase.__repr__ s:}}!!'', HchhtCRy&9::r9c4SURR-$)Nz Doctest: rrs r7shortDescriptionDocTestCase.shortDescription sT]]////r9)rrrrrr)r#NNN)r@rArBrCrrrrrr"r rrr<rtr^rrDr?r9r7rrsMAE%!*M2 FP"5(;nnG0r9rc0\rSrSrSrSrSrSr\rSr g)SkipDocTestCasei c<Xl[RUS5 gr/)rirr)r=ris r7rSkipDocTestCase.__init__ s T4(r9c&URS5 g)Nz-DocTestSuite will not work with -O2 and above)skipTestrs r7rSkipDocTestCase.setUp s EFr9cgr/r?rs r7 test_skipSkipDocTestCase.test_skip  r9c4SURR-$)NzSkipping tests from %s)rir@rs r7r SkipDocTestCase.shortDescription s'$++*>*>>>r9)riN) r@rArBrCrrrrr^rDr?r9r7rr s)G ?Gr9rc\rSrSrSrSrg) _DocTestSuitei cgr/r?)r=rs r7_removeTestAtIndex _DocTestSuite._removeTestAtIndex rr9r?N)r@rArBrCrrDr?r9r7rr s r9rc Uc [5n[U5nURXUS9nU(dD[RR S:a&[ 5nUR[U55 U$UR5 [ 5nUHjn[UR5S:XaMUR(d URnUSSS:XaUSSnXl UR[U40UD65 Ml U$)Nrqrr#rrr)rrkrrarToptimizeraddTestrrgrJrr|rr) rirSri test_finderrrjsuiterr|s r7rr sJ#o v &F   VZ  HE SYY''!+ of-.  JJL OE t}}  " }}H}&#CR=$M k$2'23 Lr9c&\rSrSrSrSrSrSrg) DocFileCasei cjSRURRRS55$)Nrr)rrrKrrs r7r DocFileCase.id s&xx **00566r9c.URR$r/)rr|rs r7r<DocFileCase.__repr__ s}}%%%r9cnSURR<SURR<SU<3$)Nrrz ", line 0 )rrKr|)r=rs r7rDocFileCase.format_failure s(==%%t}}'='=sD r9r?N)r@rArBrCr r<rrDr?r9r7rr s7&r9rc Uc0nOUR5nU(aU(d [S5e[XUU=(d S5uppSU;aXS'[RR U5nUR XsXS5n [U 40UD6$)Nrxrrr#)rrrrrryr%r) rr~r}rSrYrurdocrKrs r7 DocFileTestr s } +, ,to'274IC j 77  D !D   c$a 8D t 'w ''r9c[5nURSS5(a[URS55US'UHnUR[ U40UD65 M U$)Nr~Tr})rrPrkrr)pathskwrrs r7rr s^p OE  vv&&)"&&*;<9  k$-"-. Lr9c/n[5RU5Hn[U[5(apUR UR SS5 UR nU(a=UR S5 XRS5SSVs/sHnSU-PM sn- nMMUURS5SSVs/sHn[U5PM sn- nM U(a+USS:Xa"UR5 U(a USS:XaM"U(a,USS:Xa#URS5 U(a USS:XaM#SRU5S-$s snfs snf)Nrz # Expected:rz## rr#) rr!r\rrrrrrrr)rrpiecerrs r7rrQ s>tF&&q) eW % % MM%,,s+ ,::D m,JJt,>2G N 0s A7A7c2[U5n[X1U5 gr/)r debug_script)srcpmrSrs r7r!r! s"3'Ge$r9cSSKnU(aUR5nO0nU(a[XU5 gUR "SS9RSU-X"5 g! [[R "5S5 UR "SS9nUR5 URS[R "5S5 g=f)Nr#rGT)rrzexec(%r)) rrrrrarrr interactionr)rrrSrps r7rr s    3 U # "":#3UB  3 #,,.# $&A GGI MM$ q 1 2s AA+Cc\[U5n[X5n[X2UR5 gr/)rkr rrd)rirKrrs r7r"r" s&v &F&Gfoo.r9c&\rSrSrSrSrSrSrg) _TestClassi cXlgr/r)r=rs r7r_TestClass.__init__ s r9c.URS-UlU$)Nrrrs r7square_TestClass.square s88q= r9cUR$r/rrs r7rP_TestClass.get s xxr9rN)r@rArBrCrrrPrDr?r9r7rr sr9rz Example of a string object, searched as-is. >>> x = 1; y = 2 >>> x + y, x * y (3, 2) a In 2.2, boolean expressions displayed 0 or 1. By default, we still accept them. This can be disabled by passing DONT_ACCEPT_TRUE_FOR_1 to the new optionflags argument. >>> 4 == 4 1 >>> 4 == 4 True >>> 4 > 4 0 >>> 4 > 4 False z Blank lines can be marked with : >>> print('foo\n\nbar\n') foo bar z If the ellipsis flag is used, then '...' can be used to elide substrings in the desired output: >>> print(list(range(1000))) #doctest: +ELLIPSIS [0, 1, 2, ..., 999] a If the whitespace normalization flag is used, then differences in whitespace are ignored. >>> print(list(range(30))) #doctest: +NORMALIZE_WHITESPACE [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29] )rrzbool-int equivalencez blank linesellipsiszwhitespace normalizationc SSKnURSS9nURSSSSSS 9 URS S S [R 5/S S9 URSSSSS9 URSSSS9 UR 5nUR nURnSnURHnU[U-nM UR(a U[-nUHnURS5(am[RRU5up[RR!SU5 [#USS5n [RS [%XUS9upO ['USXES9upU (dM g g)Nr#zdoctest runner) descriptionrz --verbose store_trueFz'print very verbose output for all tests)actiondefaulthelpz-oz--optionrzqspecify a doctest option flag to apply to the test run; may be specified more than once to apply multiple options)rchoicesrrz-fz --fail-fastzystop running tests after first failure (this is a shorthand for -o FAIL_FAST, and is in addition to any other -o options))rrrr9z file containing the tests to run)nargsrz.pyrp)r~rXrrG)argparseArgumentParser add_argumentrHkeys parse_argsrrXr= fail_fastrrrrrrainsertr^rr) rrYr testfilesrXrr=r|dirnamer rrs r7_testr9 s  $ $1A $ BF k,FH j 3 8 8 :BEG  mLFH c?A    D IllGG++&v.. ~~9   U # #!# h 7 G HHOOAw '8CR=)A !!'JKHa"8U-4KKH 8 r9r)r)r+) NNNNTr#NFF)FNoNameNr#r)FN)F)[ __docformat____all__rNrMrrZrbrrrrarrior$r% collectionsr&rr'r(r*rHrrrrrrrr r r r r rrrErrWrkrprrrrrrrrrrvrrrrrrOdictr]r(r Exceptionrrrrrrrrr}rrrr TestSuiterrrrrrr r!rr"rrrr@exitr?r9r7rsZ`& + Z 2".&*],>?&LO--EF+,CD*+AB z *6"-.GH*)*()  , ,#>2 ">2 ">2 /0KL  ,   -- !& >2D"$/     /b4"%CGG"%J ,\B$B$HGDGDZd;d;VMMf o/o/dD4KCP5P5dY&)&e1-e1\ 373705fLR(,$dU=?yLx:B:;46!Hb0(##b0Hk" H&& >@ + '+D=?(4CRP$d % C( /**X%%( )Q0 f* Z zHHUWr9