tzh
2024-08-22 c7d0944258c7d0943aa7b2211498fd612971ce27
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
30
31
32
X\¬Qc@s×dZddlZddlZddlmZmZmZmZddlmZdej    fd„ƒYZ
de
fd„ƒYZ d    e
fd
„ƒYZ d e
fd „ƒYZ d „ZedkrÓejddƒndS(s(TestCases for distributed transactions.
iÿÿÿÿN(tdbt test_supporttget_new_environment_pathtget_new_database_path(tverbosetDBTxn_distributedcBsPeZdZeZeZd„Zd„Zd„Z    d„Z
d„Z d„Z RS(iÒcCsLtjƒ|_|jj|jƒ|jj|jdƒ|jj|jdƒ|jj|jdƒ|jr‰|jj    tj
t ƒn|jj |j tjtjBtjBtjBtjBtjBtjBdƒtj|jƒ|_|jjtjƒ|rH|jjƒ}|jj |jtjtjtjBdd|ƒ|jƒndS(Nii¶ttxn(RtDBEnvtdbenvt
set_tx_maxtnum_txnstset_lk_max_lockerstset_lk_max_lockstset_lk_max_objectstnosynct    set_flagst DB_TXN_NOSYNCtTruetopenthomeDirt    DB_CREATEt    DB_THREADt
DB_RECOVERt DB_INIT_TXNt DB_INIT_LOGt DB_INIT_MPOOLt DB_INIT_LOCKtDBt
set_re_lent DB_GID_SIZEt    txn_begintfilenametDB_QUEUEtcommit(tselft must_open_dbR((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyt _create_envs$    )cCs%tƒ|_d|_|jdtƒS(NttestR#(RRRR$R(R"((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pytsetUp's     cCsM|jstjƒd dkr/|jjƒn|jjƒ|jjƒdS(Niii(ii(RRtversionRt    log_flushtclose(R"((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyt _destroy_env,s cCs|jƒtj|jƒdS(N(R*RtrmtreeR(R"((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyttearDown2s
cCs|jƒ|j|ƒdS(N(R*R$(R"R#((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyt _recreate_env6s
c CsÙtƒ}d„}ddl}|jddkr=d„}nxt|jƒD]n}|jjƒ}dtj}|||ƒ}|jj    ||d|dtj
ƒ|j |ƒ|j |ƒqMW~|j |jƒ|jjƒ}|j|jt|ƒƒx'|D]\}}|j||kƒqW~~|j |jƒ|jjƒ}|j|jt|ƒƒtƒ}tƒ}    d}
x•|D]\}}|
dks¥|
d    kr¿|    j |ƒ|jƒnE|
d
krØ|jƒn,|
dkr|jƒ|j |ƒd}
n|
d    7}
qW~~|j |jƒ|jjƒ}|jt|ƒt|ƒƒx|D]\}}|jƒqZW~~|j d tƒ|jjƒ}|jt|ƒdkƒ|jt|    ƒ|jjƒd ƒdS( NcSs|S(N((tx((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyt<lambda><siÿÿÿÿiicSs t|dƒS(Ntascii(tbytes(R.((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyR/?ss%%%ddRtflagsiiR#tnkeys(tsettsyst version_infotxrangeR
RRRRtputt    DB_APPENDtaddtprepareR-R#t txn_recovert assertEqualtlent
assertTrueR!taborttdiscardRtstat( R"ttxnstadaptR5tiRtgidtrecovered_txnst discard_txnstcommitted_txnststate((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyttest01_distributed_transactions:sd           "              
     ( t__name__t
__module__R
RRtFalseR#R$R&R*R,R-RK(((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyRs                    tDBTxn_distributedSYNCcBseZeZRS((RLRMRNR(((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyRO€stDBTxn_distributed_must_open_dbcBseZeZRS((RLRMRR#(((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyRPƒst"DBTxn_distributedSYNC_must_open_dbcBseZeZeZRS((RLRMRNRRR#(((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyRQ†scCs’tjƒ}tjƒdkrM|jtjtƒƒ|jtjtƒƒntjƒdkrŽ|jtjtƒƒ|jtjt    ƒƒn|S(Niii(ii(ii(
tunittestt    TestSuiteRR'taddTestt    makeSuiteRRORPRQ(tsuite((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyt
test_suiteŒs t__main__t defaultTestRW(t__doc__tosRRttest_allRRRRRtTestCaseRRORPRQRWRLtmain(((sp/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/bsddb/test/test_distributed_transactions.pyt<module>s  "r