Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
ZEO
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
ZEO
Commits
6222e53a
Commit
6222e53a
authored
May 13, 2010
by
Jim Fulton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated a test to make it a little less prone to spurious failures.
parent
a137e195
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
11 deletions
+17
-11
src/ZEO/tests/ConnectionTests.py
src/ZEO/tests/ConnectionTests.py
+9
-4
src/ZEO/tests/protocols.test
src/ZEO/tests/protocols.test
+8
-7
No files found.
src/ZEO/tests/ConnectionTests.py
View file @
6222e53a
...
...
@@ -592,7 +592,7 @@ class InvqTests(CommonSetupTearDown):
invq
=
3
def
checkQuickVerificationWith2Clients
(
self
):
perstorage
=
self
.
openClientStorage
(
cache
=
"test"
)
perstorage
=
self
.
openClientStorage
(
cache
=
"test"
,
cache_size
=
4000
)
self
.
assertEqual
(
perstorage
.
verify_result
,
"empty cache"
)
self
.
_storage
=
self
.
openClientStorage
()
...
...
@@ -610,14 +610,19 @@ class InvqTests(CommonSetupTearDown):
revid2
=
self
.
_dostore
(
oid2
)
revid2
=
self
.
_dostore
(
oid2
,
revid2
)
# sync() is needed to prevent invalidation for oid from arriving
# in the middle of the load() call.
perstorage
.
sync
()
perstorage
.
load
(
oid
,
''
)
perstorage
.
close
()
forker
.
wait_until
(
lambda
:
os
.
path
.
exists
(
'test-1.zec'
))
revid
=
self
.
_dostore
(
oid
,
revid
)
perstorage
=
self
.
openClientStorage
(
cache
=
"test"
)
forker
.
wait_until
(
(
lambda
:
perstorage
.
verify_result
==
"quick verification"
),
onfail
=
(
lambda
:
None
))
self
.
assertEqual
(
perstorage
.
verify_result
,
"quick verification"
)
self
.
assertEqual
(
perstorage
.
_server
.
_last_invals
,
(
revid
,
[
oid
]))
...
...
src/ZEO/tests/protocols.test
View file @
6222e53a
...
...
@@ -47,10 +47,10 @@ A current client should be able to connect to a old server:
>>> conn2.root()['
blob2
'].open('
w
').write('
blob
data
2
')
>>> transaction.commit()
>>> conn.sync()
>>> conn.root().x
5
>>> @wait_until("Get the new data")
... def f():
... conn.sync()
... return conn.root().x ==
5
>>> db.close()
...
...
@@ -132,9 +132,10 @@ Note that we'll have to pull some hijinks:
>>> transaction.commit()
>>> conn.sync()
>>> conn.root().x
5
>>> @wait_until()
... def x_to_be_5():
... conn.sync()
... return conn.root().x == 5
>>> db.close()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment