= = = = = = = = = = = = = = = = = = = = = = = = = = = = =   t e s t   s e s s i o n   s t a r t s   = = = = = = = = = = = = = = = = = = = = = = = = = = = = = 
 
 p l a t f o r m   w i n 3 2   - -   P y t h o n   3 . 1 3 . 5 ,   p y t e s t - 9 . 0 . 1 ,   p l u g g y - 1 . 5 . 0   - -   E : \ c u d a \ m i n i c o n d a 3 \ p y t h o n . e x e 
 
 c a c h e d i r :   . p y t e s t _ c a c h e 
 
 r o o t d i r :   E : \ i d e a P r o j e c t s \ a g e n t \ T i a n G o n g 
 
 c o n f i g f i l e :   p y p r o j e c t . t o m l 
 
 p l u g i n s :   a n y i o - 4 . 1 2 . 1 ,   l a n g s m i t h - 0 . 6 . 2 ,   a s y n c i o - 1 . 3 . 0 ,   t i m e o u t - 2 . 4 . 0 ,   r e s p x - 0 . 2 2 . 0 ,   t y p e g u a r d - 4 . 4 . 4 
 
 a s y n c i o :   m o d e = M o d e . A U T O ,   d e b u g = F a l s e ,   a s y n c i o _ d e f a u l t _ f i x t u r e _ l o o p _ s c o p e = N o n e ,   a s y n c i o _ d e f a u l t _ t e s t _ l o o p _ s c o p e = f u n c t i o n 
 
 c o l l e c t i n g   . . .   c o l l e c t e d   2   i t e m s 
 
 
 
 t e s t s / t e s t _ m a r k e t p l a c e . p y : : t e s t _ v a l i d a t e _ a r t i f a c t _ f o r _ p u b l i s h   F A I L E D           [   5 0 % ] 
 
 t e s t s / t e s t _ m a r k e t p l a c e . p y : : t e s t _ p u b l i s h _ a g e n t _ s u c c e s s   F A I L E D                           [ 1 0 0 % ] 
 
 
 
 = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =   F A I L U R E S   = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = 
 
 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _   t e s t _ v a l i d a t e _ a r t i f a c t _ f o r _ p u b l i s h   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
 
 
 
 t m p _ p a t h   =   W i n d o w s P a t h ( ' C : / U s e r s / Z h a n g j i n q i a n / A p p D a t a / L o c a l / T e m p / p y t e s t - o f - Z h a n g j i n q i a n / p y t e s t - 4 1 / t e s t _ v a l i d a t e _ a r t i f a c t _ f o r _ p u b 0 ' ) 
 
 
 
         d e f   t e s t _ v a l i d a t e _ a r t i f a c t _ f o r _ p u b l i s h ( t m p _ p a t h ) : 
 
                 " " " KmՋl[S^MRv,g0W!h" " " 
 
                 a r t i f a c t _ d i r   =   t m p _ p a t h   /   " t e s t _ a r t i f a c t " 
 
                 a r t i f a c t _ d i r . m k d i r ( ) 
 
         
 
                 #   1 .   l	gNUOeNe
 
 >               v a l i d ,   e r r o r s   =   v a l i d a t e _ a r t i f a c t _ f o r _ p u b l i s h ( a r t i f a c t _ d i r ) 
 
                                                 ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ 
 
 
 
 t e s t s \ t e s t _ m a r k e t p l a c e . p y : 1 8 :   
 
 _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _   _ 
 
 
 
 a r t i f a c t _ d i r   =   W i n d o w s P a t h ( ' C : / U s e r s / Z h a n g j i n q i a n / A p p D a t a / L o c a l / T e m p / p y t e s t - o f - Z h a n g j i n q i a n / p y t e s t - 4 1 / t e s t _ v a l i d a t e _ a r t i f a c t _ f o r _ p u b 0 / t e s t _ a r t i f a c t ' ) 
 
 
 
         d e f   v a l i d a t e _ a r t i f a c t _ f o r _ p u b l i s h ( a r t i f a c t _ d i r :   P a t h )   - >   t u p l e [ b o o l ,   l i s t [ s t r ] ] : 
 
                 " " " 
 
                 ,g0W!hl[/f&TnS^Bl0
 
         
 
                 R e t u r n s : 
 
                         ( /f&TǏ,   Rh) 
 
                 " " " 
 
                 e r r o r s   =   [ ] 
 
         
 
                 #   1 .   hg  t i a n g o n g . y a m l   /f&TX[(W
 
                 y a m l _ f i l e   =   a r t i f a c t _ d i r   /   " t i a n g o n g . y a m l " 
 
                 i f   n o t   y a m l _ f i l e . e x i s t s ( ) : 
 
                         e r r o r s . a p p e n d ( " \ u 2 7 4 c   \ u 7 f 3 a \ u 5 c 1 1   ` t i a n g o n g . y a m l `   \ u 5 1 4 3 \ u 6 5 7 0 \ u 6 3 6 e \ u 6 5 8 7 \ u 4 e f 6 " ) 
 
                 e l s e : 
 
                         t r y : 
 
                                 i m p o r t   y a m l 
 
                                 m e t a   =   y a m l . s a f e _ l o a d ( y a m l _ f i l e . r e a d _ t e x t ( e n c o d i n g = " u t f - 8 " ) ) 
 
                         e x c e p t   I m p o r t E r r o r : 
 
                                 #   Yglň  y a m l \Ջ  J S O N   fN
 
                                 j s o n _ f i l e   =   a r t i f a c t _ d i r   /   " t i a n g o n g . j s o n " 
 
                                 i f   j s o n _ f i l e . e x i s t s ( ) : 
 
                                         m e t a   =   j s o n . l o a d s ( j s o n _ f i l e . r e a d _ t e x t ( e n c o d i n g = " u t f - 8 " ) ) 
 
                                 e l s e : 
 
                                         e r r o r s . a p p e n d ( " \ u 2 7 4 c   \ u 6 5 e 0 \ u 6 c d 5 \ u 8 9 e 3 \ u 6 7 9 0   ` t i a n g o n g . y a m l ` \ u f f 0 8 \ u 7 f 3 a \ u 5 c 1 1   p y y a m l   \ u 4 f 9 d \ u 8 d 5 6 \ u f f 0 9 " ) 
 
                                         m e t a   =   { } 
 
                         e x c e p t   E x c e p t i o n   a s   e : 
 
                                 e r r o r s . a p p e n d ( f " \ u 2 7 4 c   ` t i a n g o n g . y a m l `   \ u 8 9 e 3 \ u 6 7 9 0 \ u 5 9 3 1 \ u 8 d 2 5 :   { e } " ) 
 
                                 m e t a   =   { } 
 
         
 
                         i f   m e t a : 
 
                                 r e q u i r e d _ f i e l d s   =   [ " n a m e " ,   " d e s c r i p t i o n " ,   " e n t r y " ,   " v e r s i o n " ] 
 
                                 f o r   f i e l d   i n   r e q u i r e d _ f i e l d s : 
 
                                         i f   n o t   m e t a . g e t ( f i e l d ) : 
 
                                                 e r r o r s . a p p e n d ( f " \ u 2 7 4 c   ` t i a n g o n g . y a m l `   \ u 7 f 3 a \ u 5 c 1 1 \ u 5 f c 5 \ u 5 8 6 b \ u 5 b 5 7 \ u 6 b b 5 :   ` { f i e l d } ` " ) 
 
         
 
                 #   2 .   hg  R E A D M E . m d 
 
                 r e a d m e   =   a r t i f a c t _ d i r   /   " R E A D M E . m d " 
 
                 i f   n o t   r e a d m e . e x i s t s ( ) : 
 
                         e r r o r s . a p p e n d ( " \ u 2 7 4 c   \ u 7 f 3 a \ u 5 c 1 1   ` R E A D M E . m d `   \ u 4 f 7 f \ u 7 5 2 8 \ u 8 b f 4 \ u 6 6 0 e " ) 
 
                 e l s e : 
 
                         c o n t e n t   =   r e a d m e . r e a d _ t e x t ( e n c o d i n g = " u t f - 8 " ,   e r r o r s = " i g n o r e " ) 
 
                         i f   l e n ( c o n t e n t )   <   1 0 0 : 
 
                                 e r r o r s . a p p e n d ( f " \ u 2 7 4 c   ` R E A D M E . m d `   \ u 5 1 8 5 \ u 5 b b 9 \ u 8 f c 7 \ u 5 c 1 1 \ u f f 0 8 { l e n ( c o n t e n t ) }   \ u 5 b 5 7 \ u 7 b 2 6 \ u f f 0 c \ u 8 9 8 1 \ u 6 c 4 2   \ u 2 2 6 5   1 0 0 \ u f f 0 9 " ) 
 
         
 
                 #   3 .   hgeQSeN
 
 >               i f   m e t a   a n d   m e t a . g e t ( " e n t r y " ) : 
 
                       ^ ^ ^ ^ 
 
 E               U n b o u n d L o c a l E r r o r :   c a n n o t   a c c e s s   l o c a l   v a r i a b l e   ' m e t a '   w h e r e   i t   i s   n o t   a s s o c i a t e d   w i t h   a   v a l u e 
 
 
 
 t i a n g o n g \ m a r k e t p l a c e . p y : 8 4 :   U n b o u n d L o c a l E r r o r 
 
 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _   t e s t _ p u b l i s h _ a g e n t _ s u c c e s s   _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
 
 
 
 m o c k _ c o n f i g   =   < M a g i c M o c k   n a m e = ' c o n f i g '   i d = ' 1 6 1 0 4 2 0 7 4 0 7 2 0 ' > 
 
 m o c k _ p o s t   =   < A s y n c M o c k   n a m e = ' p o s t '   i d = ' 1 6 1 0 4 2 0 7 4 1 3 9 2 ' > 
 
 t m p _ p a t h   =   W i n d o w s P a t h ( ' C : / U s e r s / Z h a n g j i n q i a n / A p p D a t a / L o c a l / T e m p / p y t e s t - o f - Z h a n g j i n q i a n / p y t e s t - 4 1 / t e s t _ p u b l i s h _ a g e n t _ s u c c e s s 0 ' ) 
 
 
 
         @ p y t e s t . m a r k . a s y n c i o 
 
         @ p a t c h ( " t i a n g o n g . m a r k e t p l a c e . h t t p x . A s y n c C l i e n t . p o s t " ) 
 
         @ p a t c h ( " t i a n g o n g . m a r k e t p l a c e . c o n f i g " ) 
 
         a s y n c   d e f   t e s t _ p u b l i s h _ a g e n t _ s u c c e s s ( m o c k _ c o n f i g ,   m o c k _ p o s t ,   t m p _ p a t h ) : 
 
                 " " " KmՋޘGS
NLu  ( O(u  m o c k ) " " " 
 
                 m o c k _ c o n f i g . F O R G E _ D I R   =   s t r ( t m p _ p a t h ) 
 
                 m o c k _ c o n f i g . G I T H U B _ T O K E N   =   " f a k e _ t o k e n " 
 
                 m o c k _ c o n f i g . G I T H U B _ R E P O _ O W N E R   =   " t e s t " 
 
                 m o c k _ c o n f i g . G I T H U B _ R E P O _ N A M E   =   " r e p o " 
 
                 m o c k _ c o n f i g . G I T H U B _ U S E R N A M E   =   " t e s t e r " 
 
         
 
                 #   g Tlvl[vU_
 
                 a r t i f a c t _ n a m e   =   " m o c k _ a r t i f a c t " 
 
                 a r t i f a c t _ d i r   =   t m p _ p a t h   /   a r t i f a c t _ n a m e 
 
                 a r t i f a c t _ d i r . m k d i r ( ) 
 
                 ( a r t i f a c t _ d i r   /   " t i a n g o n g . y a m l " ) . w r i t e _ t e x t ( " n a m e :   t e s t \ n d e s c r i p t i o n :   T e s t \ n e n t r y :   m a i n . p y \ n v e r s i o n :   1 . 0 . 0 " ,   e n c o d i n g = " u t f - 8 " ) 
 
                 ( a r t i f a c t _ d i r   /   " R E A D M E . m d " ) . w r i t e _ t e x t ( " = "   *   1 0 0 ,   e n c o d i n g = " u t f - 8 " ) 
 
                 ( a r t i f a c t _ d i r   /   " m a i n . p y " ) . w r i t e _ t e x t ( " " ,   e n c o d i n g = " u t f - 8 " ) 
 
         
 
                 #   M o c k   H T T P   T^
 
                 m o c k _ r e s p   =   A s y n c M o c k ( ) 
 
                 m o c k _ r e s p . s t a t u s _ c o d e   =   2 0 1 
 
                 m o c k _ r e s p . j s o n . r e t u r n _ v a l u e   =   { " n u m b e r " :   4 2 ,   " h t m l _ u r l " :   " h t t p s : / / g i t h u b . c o m / t e s t / r e p o / i s s u e s / 4 2 " } 
 
                 m o c k _ p o s t . r e t u r n _ v a l u e   =   m o c k _ r e s p 
 
         
 
                 r e s u l t   =   a w a i t   p u b l i s h _ a g e n t ( a r t i f a c t _ n a m e ) 
 
 >               a s s e r t   " \ u 2 7 0 5   \ u 9 8 d e \ u 5 3 4 7 \ u 4 e 0 a \ u 7 5 4 c \ u 6 2 1 0 \ u 5 2 9 f \ u f f 0 1 "   i n   r e s u l t 
 
 E               a s s e r t   ' \ u 2 7 0 5   \ u 9 8 d e \ u 5 3 4 7 \ u 4 e 0 a \ u 7 5 4 c \ u 6 2 1 0 \ u 5 2 9 f \ u f f 0 1 '   i n   " \ u 2 7 4 c   \ u 9 8 d e \ u 5 3 4 7 \ u 5 9 3 1 \ u 8 d 2 5 :   ' c o r o u t i n e '   o b j e c t   i s   n o t   s u b s c r i p t a b l e " 
 
 
 
 t e s t s \ t e s t _ m a r k e t p l a c e . p y : 6 4 :   A s s e r t i o n E r r o r 
 
 = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =   w a r n i n g s   s u m m a r y   = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = 
 
 t e s t s / t e s t _ m a r k e t p l a c e . p y : : t e s t _ p u b l i s h _ a g e n t _ s u c c e s s 
 
     E : \ i d e a P r o j e c t s \ a g e n t \ T i a n G o n g \ t e s t s \ t e s t _ m a r k e t p l a c e . p y : 6 3 :   R u n t i m e W a r n i n g :   c o r o u t i n e   ' A s y n c M o c k M i x i n . _ e x e c u t e _ m o c k _ c a l l '   w a s   n e v e r   a w a i t e d 
 
         r e s u l t   =   a w a i t   p u b l i s h _ a g e n t ( a r t i f a c t _ n a m e ) 
 
     E n a b l e   t r a c e m a l l o c   t o   g e t   t r a c e b a c k   w h e r e   t h e   o b j e c t   w a s   a l l o c a t e d . 
 
     S e e   h t t p s : / / d o c s . p y t e s t . o r g / e n / s t a b l e / h o w - t o / c a p t u r e - w a r n i n g s . h t m l # r e s o u r c e - w a r n i n g s   f o r   m o r e   i n f o . 
 
 
 
 - -   D o c s :   h t t p s : / / d o c s . p y t e s t . o r g / e n / s t a b l e / h o w - t o / c a p t u r e - w a r n i n g s . h t m l 
 
 = = = = = = = = = = = = = = = = = = = = = = = = = = =   s h o r t   t e s t   s u m m a r y   i n f o   = = = = = = = = = = = = = = = = = = = = = = = = = = = 
 
 F A I L E D   t e s t s / t e s t _ m a r k e t p l a c e . p y : : t e s t _ v a l i d a t e _ a r t i f a c t _ f o r _ p u b l i s h   -   U n b o u n . . . 
 
 F A I L E D   t e s t s / t e s t _ m a r k e t p l a c e . p y : : t e s t _ p u b l i s h _ a g e n t _ s u c c e s s   -   a s s e r t   ' \ u 2 7 0 5   \ u 9 8 d e . . . 
 
 = = = = = = = = = = = = = = = = = = = = = = = =   2   f a i l e d ,   1   w a r n i n g   i n   0 . 4 3 s   = = = = = = = = = = = = = = = = = = = = = = = = = 
 
 