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
0017bbdc
Commit
0017bbdc
authored
May 08, 2001
by
Jeremy Hylton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add new tests from ZEO2.
XXX The two cache invalidation tests fails currently.
parent
2224b1aa
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
8 deletions
+14
-8
src/ZEO/tests/testZEO.py
src/ZEO/tests/testZEO.py
+14
-8
No files found.
src/ZEO/tests/testZEO.py
View file @
0017bbdc
...
...
@@ -9,16 +9,18 @@ import unittest
import
ZEO.ClientStorage
,
ZEO
.
StorageServer
import
ThreadedAsync
,
ZEO
.
trigger
from
ZODB.FileStorage
import
FileStorage
from
ZEO.tests
import
forker
from
ZEO.tests
import
forker
,
Cache
# Sorry Jim...
from
ZODB.tests
import
StorageTestBase
,
BasicStorage
,
VersionStorage
,
\
TransactionalUndoStorage
,
TransactionalUndoVersionStorage
,
\
PackableStorage
,
Synchronization
PackableStorage
,
Synchronization
,
ConflictResolution
from
ZODB.tests.MinPO
import
MinPO
ZERO
=
'
\
0
'
*
8
import
pickle
class
DummyDB
:
def
invalidate
(
self
,
*
args
):
...
...
@@ -59,9 +61,9 @@ class ZEOTestBase(StorageTestBase.StorageTestBase):
if
revid
is
None
:
revid
=
ZERO
if
data
is
None
:
data
=
7
data
=
MinPO
(
7
)
if
not
already_pickled
:
data
=
pickle
.
dumps
(
data
)
data
=
StorageTestBase
.
zodb_pickle
(
data
)
if
version
is
None
:
version
=
''
# Begin the transaction
...
...
@@ -91,12 +93,18 @@ class ZEOTestBase(StorageTestBase.StorageTestBase):
raise
serial
d
[
oid
]
=
serial
return
d
def
checkLargeUpdate
(
self
):
obj
=
MinPO
(
"X"
*
(
10
*
128
*
1024
))
self
.
_dostore
(
data
=
obj
)
class
GenericTests
(
ZEOTestBase
,
Cache
.
StorageWithCache
,
BasicStorage
.
BasicStorage
,
VersionStorage
.
VersionStorage
,
PackableStorage
.
PackableStorage
,
Synchronization
.
SynchronizedStorage
,
ConflictResolution
.
ConflictResolvingStorage
,
):
"""An abstract base class for ZEO tests
...
...
@@ -133,14 +141,12 @@ class GenericTests(ZEOTestBase,
class
ZEOFileStorageTests
(
GenericTests
):
__super_setUp
=
GenericTests
.
setUp
from
ZODB.FileStorage
import
FileStorage
def
setUp
(
self
):
self
.
__fs_base
=
tempfile
.
mktemp
()
self
.
__super_setUp
()
def
getStorage
(
self
):
return
self
.
FileStorage
(
self
.
__fs_base
,
create
=
1
)
return
FileStorage
(
self
.
__fs_base
,
create
=
1
)
def
delStorage
(
self
):
# file storage appears to create three files
...
...
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