ó
wŰjc           @   s  d  d l  Z  d  d l Z d  d l m Z d  d l m Z d  d l m Z m Z m	 Z	 m
 Z
 m Z m Z d e e e	 f d     YZ d e f d     YZ d	 e f d
     YZ d e
 f d     YZ d e f d     YZ d e f d     YZ d   Z e d k re   n  d S(   i˙˙˙˙N(   t   StringIO(   t   test_support(   t   AbstractUnpickleTestst   AbstractPickleTestst   AbstractPickleModuleTestst   AbstractPersistentPicklerTestst#   AbstractPicklerUnpicklerObjectTestst   BigmemPickleTestst   PickleTestsc        	   B   st   e  Z d  d  d  Z d   Z e Z e Z e f Z	 e e j
 e e e f Z e j
 e e e e j e e e e f	 Z RS(   i    c         C   s   t  j | |  S(   N(   t   picklet   dumps(   t   selft   argt   protot   fast(    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR
      s    c         C   s   t  j |  S(   N(   R	   t   loads(   R   t   buf(    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR      s    (   t   __name__t
   __module__R
   R   R	   t   modulet   KeyErrort   errort
   IndexErrort   bad_stack_errorst   UnpicklingErrort	   TypeErrort   AttributeErrort   EOFErrort   bad_mark_errorst
   ValueErrort   structt   ImportErrort   truncated_errors(    (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR      s   				t   UnpicklerTestsc        	   B   s_   e  Z e Z e f Z e e j e e	 e
 f Z e j e
 e	 e e j e e e e f	 Z d    Z RS(   c         C   s%   t  |  } t j |  } | j   S(   N(   R    R	   t	   Unpicklert   load(   R   R   t   ft   u(    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR   .   s    (   R   R   R   R   R   R   R	   R   R   R   R   R   R   R   R   R    R   (    (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR!   #   s   			t   PicklerTestsc           B   s    e  Z d  d  d  Z d   Z RS(   i    c         C   sQ   t    } t j | |  } | r- | | _ n  | j |  | j d  | j   S(   Ni    (   R    R	   t   PicklerR   t   dumpt   seekt   read(   R   R   R   R   R$   t   p(    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR
   5   s    	c         C   s%   t  |  } t j |  } | j   S(   N(   R    R	   R"   R#   (   R   R   R$   R%   (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR   >   s    (   R   R   R
   R   (    (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR&   3   s   	t   PersPicklerTestsc           B   s    e  Z d  d  d  Z d   Z RS(   i    c            sm   d t  j f   f d     Y} t   } | | |  } | rI | | _ n  | j |  | j d  | j   S(   Nt   PersPicklerc              s   e  Z   f d    Z RS(   c            s     j  |  S(   N(   t   persistent_id(   t   subselft   obj(   R   (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR.   G   s    (   R   R   R.   (    (   R   (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR-   F   s   i    (   R	   R'   R    R   R(   R)   R*   (   R   R   R   R   R-   R$   R+   (    (   R   s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR
   E   s    	c            sA   d t  j f   f d     Y} t |  } | |  } | j   S(   Nt   PersUnpicklerc              s   e  Z   f d    Z RS(   c            s     j  |  S(   N(   t   persistent_load(   R/   R0   (   R   (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR2   S   s    (   R   R   R2   (    (   R   (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR1   R   s   (   R	   R"   R    R#   (   R   R   R1   R$   R%   (    (   R   s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR   Q   s    (   R   R   R
   R   (    (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR,   C   s   t   PicklerUnpicklerObjectTestsc           B   s   e  Z e j Z e j Z RS(    (   R   R   R	   R'   t   pickler_classR"   t   unpickler_class(    (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR3   Y   s   	t   PickleBigmemPickleTestsc           B   s    e  Z d  d  d  Z d   Z RS(   i    c         C   s   t  j | |  S(   N(   R	   R
   (   R   R   R   R   (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR
   `   s    c         C   s   t  j |  S(   N(   R	   R   (   R   R   (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR   d   s    (   R   R   R
   R   (    (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyR6   ^   s   c           C   s-   t  j t t t t t t  t  j t	  d  S(   N(
   R   t   run_unittestR   R!   R&   R,   R3   R6   t   run_doctestR	   (    (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyt	   test_maini   s    t   __main__(   R	   R   t	   cStringIOR    t   testR   t   test.pickletesterR   R   R   R   R   R   R   R!   R&   R,   R3   R6   R9   R   (    (    (    s   /home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python-native/2.7.18/recipe-sysroot-native/usr/lib/python2.7/test/test_pickle.pyt   <module>   s   .		