-
?c       s    d  Z    d k Z  d k Z  d k Z  d k Z  d k Z  d k Z  d k Z  d k Z  d k	 Z	  d k
 Z
  d k l Z   d k l Z $ d k l Z l Z l Z l Z l Z l Z l Z l Z l Z l Z l Z ) d k l Z * d k l Z l Z l  Z  l! Z! , d f  d     YZ" 1 d	 f  d
     YZ# N d   Z$ c d e i e i e i e i e i e i e i% e i& e i' e i e i e i e i( e i) e  i  e! i! e# f d     YZ*  d e* f d     YZ+  d e+ f d     YZ,  d e+ f d     YZ- e+ e- g Z. d k/ Z/ e/ i0 o e. i1 e,  n d   Z2 e3 d j o e i4 d d  n d S(   s'   Test suite for ZEO based on ZODB.tests.N(   s   MinPO(   s   zodb_unpickle(   s   StorageTestBases   BasicStorages   VersionStorages   TransactionalUndoStorages   TransactionalUndoVersionStorages   PackableStorages   Synchronizations   ConflictResolutions   RevisionStorages	   MTStorages   ReadOnlyStorage(   s   ClientStorage(   s   forkers   Caches   CommitLockTestss   ThreadTestss   DummyDBc      s   , t  Z - d   Z RS(   Nc    s
   - . d  S(   N(    (   s   selfs   args(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys
   invalidate- s   (   s   __name__s
   __module__s
   invalidate(    (    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   DummyDB, s   	s   MiscZEOTestsc      s,   1 t  Z d  Z 2 4 d   Z 8 d   Z RS(   s&   ZEO tests that don't fit in elsewhere.c    s5   4 5 t  d d d d  } 6 |  i d |  d  S(   Ns   Xi
   i   i   s   data(   s   MinPOs   objs   selfs   _dostore(   s   selfs   obj(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkLargeUpdate4 s   c 
   sv  8 9 |  i i } : t | d d d d }	 ; z.< |  i i   } = t d  } > |  i
 | d | } ? |	 i | d  \ } } @ |  i t |  t d   A |  i | |  B |  i
 | d t d  d	 | } C x' t d
  DC ] } F t i d  q WG |	 i | d  \ } } H |  i t |  t d  I d  J |  i | |  Wd  K L |	 i   Xd  S(   Ns   waiti   s   min_disconnect_pollf0.10000000000000001s   firsts   datas    s   seconds   revidi   s"   Invalidation message was not sent!(   s   selfs   _storages   _addrs   addrs   ClientStorages   storage2s   new_oids   oids   MinPOs   obs   _dostores   revid1s   loads   datas   serials   assertEquals   zodb_unpickles   revid2s   ranges   ns   asyncores   polls   close(
   s   selfs   addrs   datas   oids   revid2s   obs   revid1s   ns   serials   storage2(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkZEOInvalidation8 s&   $ 	
(   s   __name__s
   __module__s   __doc__s   checkLargeUpdates   checkZEOInvalidation(    (    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   MiscZEOTests1 s   c     s   N U V x t  d  DV ] } W t i d d  } X t i t i t i  }  Y zD Z y [ |  i	 d | f  Wn  \ t i
 j
 o ^ | Sn XWd _ ` |  i   Xq Wa t d  d S(   s   Return a port that is not in use.

    Checks if a port is in use by trying to connect to it.  Assumes it
    is not in use if connect raises an exception.

    Raises RuntimeError after 10 tries.
    i
   i N  i0u  s	   localhostNs   Can't find port(   s   ranges   is   randoms	   randranges   ports   sockets   AF_INETs   SOCK_STREAMs   ss   connects   errors   closes   RuntimeError(   s   ss   is   port(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   get_portN s    	s   GenericTestsc      sS   c t  Z d  Z { } d   Z  d   Z  d d  Z  d   Z  d   Z RS(   s0   Combine tests from various origins in one class.c    s   } ~ t  i d t  i d |  i     t   }  t i d | f  }  t i
 |  i    | |  \ } } } }  | g |  _  | g |  _  | |  _  t | d d d  d d d	 d
  d d |  _  |  i i t   t  d  S(   Ns   testZEOs
   setUp() %ss    s   1s
   cache_sizei -1s   min_disconnect_pollf0.5s   waiti   s   wait_timeouti<   (   s   zLOGs   LOGs   INFOs   selfs   ids   get_ports   ports   forkers	   ZEOConfigs   zconfs   start_zeo_servers	   getConfigs   zports	   adminaddrs   pids   paths   _pidss   _serverss
   _conf_paths   ClientStorages   _storages
   registerDBs   DummyDBs   None(   s   selfs   zconfs	   adminaddrs   pids   zports   paths   port(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   setUp} s   #c    s     |  i i    t i |  i   x$ |  i D ] }  t i	 |  q3 W t
 t d  o1  x' |  i D ] }  t i | d  qp Wn d  S(   Ns   waitpidi    (   s   selfs   _storages   closes   oss   removes
   _conf_paths   _serverss   servers   forkers   shutdown_zeo_servers   hasattrs   _pidss   pids   waitpid(   s   selfs   servers   pid(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   tearDown s    	 	i    c    sD     |  i i }  |  i i    t | d | d d |  _ d  S(   Ns	   read_onlys   waiti   (   s   selfs   _storages   _addrs   addrs   closes   ClientStorages	   read_only(   s   selfs	   read_onlys   addr(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   open s   c    s1     t  t d  o  t i i |   n d  S(   Ns   __version__(   s   hasattrs   ZODBs   ReadOnlyStorages   checkWriteMethodss   self(   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkWriteMethods s   c    sB     d |  i i |  i i f }  |  i |  i i   |  d  S(   Ns   %s:%s(   s   selfs   _storages   _server_addrs   keys   assertEquals   sortKey(   s   selfs   key(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkSortKey s   (   s   __name__s
   __module__s   __doc__s   setUps   tearDowns   opens   checkWriteMethodss   checkSortKey(    (    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   GenericTestsc s   

s   FileStorageTestsc      s)    t  Z d  Z   d Z  d   Z RS(   s!   Test ZEO backed by a FileStorage.i   c    s(     t  i   } |  _  d | Sd  S(   NsG           <filestorage 1>
        path %s
        </filestorage>
        (   s   tempfiles   mktemps   filenames   selfs   _FileStorageTests__fs_base(   s   selfs   filename(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys	   getConfig s   (   s   __name__s
   __module__s   __doc__s   levels	   getConfig(    (    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   FileStorageTests s   	s   BDBTestsc      s)    t  Z d  Z   d Z  d   Z RS(   s&   ZEO backed by a Berkeley full storage.i   c    s'     t  i   |  _  d |  i Sd  S(   NsI           <fullstorage 1>
        envdir %s
        </fullstorage>
        (   s   tempfiles   mktemps   selfs   _envdir(   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys	   getConfig s   (   s   __name__s
   __module__s   __doc__s   levels	   getConfig(    (    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   BDBTests s   	s   MappingStorageTestsc      s   t  Z d  Z   d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z	  d   Z
  d	   Z  d
   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z  d   Z   d   Z!  d    Z"  d!   Z#  d"   Z$  d#   Z%  d$   Z&  d%   Z'  d&   Z(  d'   Z)  d(   Z*  d)   Z+  d*   Z,  d+   Z-  d,   Z.  d-   Z/  d.   Z0  d/   Z1  d0   Z2  d1   Z3  d2   Z4  d3   Z5  d4   Z6  d5   Z7  d6   Z8 RS(7   s    ZEO backed by a Mapping storage.c    s     d Sd  S(   Ns   <mappingstorage 1/>(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys	   getConfig s   c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkVersions s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkVersionedStoreAndLoad s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkVersionedLoadErrors s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkVersionLock s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkVersionEmpty s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkUndoUnresolvable s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkUndoInvalidation s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkUndoInVersion s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkUndoCreationBranch2 s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkUndoCreationBranch1 s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkUndoConflictResolution s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkUndoCommitVersion s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkUndoAbortVersion s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackUndoLog s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkUndoLogMetadata s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkTwoObjectUndoAtOnce s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkTwoObjectUndoAgain s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkTwoObjectUndo s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys7   checkTransactionalUndoAfterPackWithObjectUnlinkFromRoot s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkTransactionalUndoAfterPack s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkSimpleTransactionalUndo s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkReadMethods s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackAfterUndoDeletion s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackAfterUndoManyTimes s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackVersions s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackUnlinkedFromRoot s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackOnlyOneObject s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackJustOldRevisions s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackEmptyStorage s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackAllRevisions s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackVersionsInPast s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkPackVersionReachable s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkNotUndoable s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys&   checkNewSerialOnCommitVersionToVersion s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkModifyAfterAbortVersion s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkLoadSerial s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys#   checkCreateObjectInVersionWithAbort s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkCommitVersionSerialno s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkCommitVersionInvalidation s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkCommitToOtherVersion s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkCommitToNonVersion s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkCommitLockUndoFinish s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkCommitLockUndoClose s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkCommitLockUndoAbort s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys#   checkCommitEmptyVersionInvalidation s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkCreationUndoneGetSerial s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkAbortVersionSerialno s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkAbortVersionInvalidation s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkAbortVersionErrors s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkAbortVersion s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys"   checkAbortOneVersionCommitTheOther s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   checkResolve s    c    s
     d  S(   N(    (   s   self(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   check4ExtStorageThread s    (9   s   __name__s
   __module__s   __doc__s	   getConfigs   checkVersionss   checkVersionedStoreAndLoads   checkVersionedLoadErrorss   checkVersionLocks   checkVersionEmptys   checkUndoUnresolvables   checkUndoInvalidations   checkUndoInVersions   checkUndoCreationBranch2s   checkUndoCreationBranch1s   checkUndoConflictResolutions   checkUndoCommitVersions   checkUndoAbortVersions   checkPackUndoLogs   checkUndoLogMetadatas   checkTwoObjectUndoAtOnces   checkTwoObjectUndoAgains   checkTwoObjectUndos7   checkTransactionalUndoAfterPackWithObjectUnlinkFromRoots   checkTransactionalUndoAfterPacks   checkSimpleTransactionalUndos   checkReadMethodss   checkPackAfterUndoDeletions   checkPackAfterUndoManyTimess   checkPackVersionss   checkPackUnlinkedFromRoots   checkPackOnlyOneObjects   checkPackJustOldRevisionss   checkPackEmptyStorages   checkPackAllRevisionss   checkPackVersionsInPasts   checkPackVersionReachables   checkNotUndoables&   checkNewSerialOnCommitVersionToVersions   checkModifyAfterAbortVersions   checkLoadSerials#   checkCreateObjectInVersionWithAborts   checkCommitVersionSerialnos   checkCommitVersionInvalidations   checkCommitToOtherVersions   checkCommitToNonVersions   checkCommitLockUndoFinishs   checkCommitLockUndoCloses   checkCommitLockUndoAborts#   checkCommitEmptyVersionInvalidations   checkCreationUndoneGetSerials   checkAbortVersionSerialnos   checkAbortVersionInvalidations   checkAbortVersionErrorss   checkAbortVersions"   checkAbortOneVersionCommitTheOthers   checkResolves   check4ExtStorageThread(    (    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   MappingStorageTests sn   c     sx   
d  k  } | i d d  t i   } x6 t D]+ } t i | d  }  | i	 |   q; W| Sd  S(   Ns   ignores   mktemps   check(
   s   warningss   filterwarningss   unittests	   TestSuites   suites   test_classess   klasss	   makeSuites   subs   addTest(   s   subs   warningss   suites   klass(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys
   test_suites   
 	s   __main__s   defaultTests
   test_suite(5   s   __doc__s   oss   syss   times   randoms   sockets   asyncores   tempfiles   unittests   zLOGs   ZODBs   ZODB.tests.MinPOs   MinPOs   ZODB.tests.StorageTestBases   zodb_unpickles
   ZODB.testss   StorageTestBases   BasicStorages   VersionStorages   TransactionalUndoStorages   TransactionalUndoVersionStorages   PackableStorages   Synchronizations   ConflictResolutions   RevisionStorages	   MTStorages   ReadOnlyStorages   ZEO.ClientStorages   ClientStorages	   ZEO.testss   forkers   Caches   CommitLockTestss   ThreadTestss   DummyDBs   MiscZEOTestss   get_ports   SynchronizedStorages   ConflictResolvingStorages!   ConflictResolvingTransUndoStorages   StorageWithCaches   TransUndoStorageWithCaches   GenericTestss   FileStorageTestss   BDBTestss   MappingStorageTestss   test_classess
   BDBStorages   is_availables   appends
   test_suites   __name__s   main(&   s   GenericTestss   Caches   asyncores   BDBTestss   CommitLockTestss   VersionStorages   unittests   randoms   BasicStorages   forkers   syss   PackableStorages   StorageTestBases   DummyDBs
   test_suites   FileStorageTestss   ConflictResolutions   MappingStorageTestss   RevisionStorages   MinPOs   ClientStorages   TransactionalUndoStorages   sockets   ReadOnlyStorages   tempfiles   oss   ThreadTestss	   MTStorages   TransactionalUndoVersionStorages   ZODBs   Synchronizations   test_classess   get_ports   times   zLOGs   zodb_unpickles   MiscZEOTestss
   BDBStorage(    (    s9   /usr/pkg/lib/python2.2/site-packages/ZEO/tests/testZEO.pys   ? s:   L"yH>