Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
ZODB
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kirill Smelkov
ZODB
Commits
5ead790c
Commit
5ead790c
authored
Mar 12, 2004
by
Jeremy Hylton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix the invalidation-during-load test to execute the branch of interest.
parent
5ec19b76
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
7 deletions
+6
-7
src/ZODB/tests/testmvcc.py
src/ZODB/tests/testmvcc.py
+6
-7
No files found.
src/ZODB/tests/testmvcc.py
View file @
5ead790c
...
...
@@ -256,7 +256,10 @@ to test the Connection code.
... self.db.invalidate(tid, {oid:1})
... self.count += 1
Now we'll repeat all the setup that was done earlier.
We can execute this test with a single connection, because we're
synthesizing the invalidation that is normally generated by the second
connection. We need to create two revisions so that there is a
non-current revision to load.
>>> ts = TestStorage()
>>> db = DB(ts)
...
...
@@ -266,6 +269,8 @@ Now we'll repeat all the setup that was done earlier.
>>> r1["a"] = MinPO(0)
>>> r1["b"] = MinPO(0)
>>> cn1.getTransaction().commit()
>>> r1["b"].value = 1
>>> cn1.getTransaction().commit()
>>> cn1.cacheMinimize()
>>> oid = r1["b"]._p_oid
...
...
@@ -280,9 +285,6 @@ False
>>> r1["b"]._p_state
-1
>>> r1["b"]._p_activate()
Traceback (most recent call last):
...
ReadConflictError: database read conflict error (oid 0000000000000002, class ZODB.tests.MinPO.MinPO)
>>> oid in cn1._invalidated
True
>>> ts.count
...
...
@@ -290,9 +292,6 @@ True
_p_independent() still has the desired effect.
We still get a non-current version if the invalidation occurs while we
are loading the current revision. Can that happen without ZEO?
Error cases:
- storage doesn't have an earlier revision
- MVCC returns current revision
...
...
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