ó o®¸Qc@s\ddlZddlTddlmZdejfd„ƒYZedkrXejƒndS(iÿÿÿÿN(t*(t getrefcounttObjectsTestCasecBsGeZd„Zd„Zd„Zd„Zd„Zd„Zd„ZRS(cCs |jt|ƒt|ƒƒdS(N(t assertEqualtid(tselftatb((s0/sys/lib/python2.7/ctypes/test/test_internals.pyt assertSamescCsKd}t|ƒ}t|ƒ}|j|t|ƒƒ|j|jdƒdS(NiûÞ€(tgrctc_intRt_objectstNone(Rtitrefcnttci((s0/sys/lib/python2.7/ctypes/test/test_internals.pyt test_intss   cCsOd}t|ƒ}t|ƒ}|j|dt|ƒƒ|j|j|ƒdS(Ns Hello, Worldi(R tc_char_pRRR (RtsRtcs((s0/sys/lib/python2.7/ctypes/test/test_internals.pyt test_c_char_ps   cCsgdtfd„ƒY}d}d}|ƒ}|j|jdƒ||_||_|j|jdƒdS(NtXcBs eZdefdefgZRS(RR(t__name__t __module__R t_fields_(((s0/sys/lib/python2.7/ctypes/test/test_internals.pyR'sirmism(t StructureRR R RR(RRRRtx((s0/sys/lib/python2.7/ctypes/test/test_internals.pyttest_simple_struct&s   csÌdtfd„ƒY‰dtf‡fd†ƒY}|ƒ}|j|jdƒˆƒˆƒ}}|||_|_|j|jiid6id6ƒd \|_|_|j|jiid6id6ƒdS( NRcBs eZdefdefgZRS(RR(RRR R(((s0/sys/lib/python2.7/ctypes/test/test_internals.pyR3stYcs eZdˆfdˆfgZRS(Rty(RRR((R(s0/sys/lib/python2.7/ctypes/test/test_internals.pyR6st0t1i*i](i*i](RRR R RRRR(RRRtx1tx2((Rs0/sys/lib/python2.7/ctypes/test/test_internals.pyttest_embedded_structs2s !cs¸dtfd„ƒY‰dtf‡fd†ƒY}d}d}ˆƒ}||_||_|j|ji|d6|d6ƒ|ƒ}||_|j|jii|d6|d6d6ƒdS( NRcBs eZdefdefgZRS(RR(RRRR(((s0/sys/lib/python2.7/ctypes/test/test_internals.pyRCsRcs eZdˆfdˆfgZRS(RR(RRR((R(s0/sys/lib/python2.7/ctypes/test/test_internals.pyRFss Hello, Worlds Hallo, WeltRR(RRRRR R(RRts1ts2RR((Rs0/sys/lib/python2.7/ctypes/test/test_internals.pyttest_xxxBs   !  cCs^dtfd„ƒY}td}|ddddƒ}|j|jdƒ|ƒ}||_dS(NRcBseZdeeƒfgZRS(tdata(RRtPOINTERR R(((s0/sys/lib/python2.7/ctypes/test/test_internals.pyRYsii ii!i,(RR RR R R&(RRtARR((s0/sys/lib/python2.7/ctypes/test/test_internals.pyttest_ptr_structXs   ( RRRRRRR"R%R)(((s0/sys/lib/python2.7/ctypes/test/test_internals.pyRs     t__main__( tunittesttctypestsysRR tTestCaseRRtmain(((s0/sys/lib/python2.7/ctypes/test/test_internals.pyts  R