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
3ed59c28
Commit
3ed59c28
authored
Mar 03, 2004
by
Jeremy Hylton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Convert testSets DeprecationWarnings into exceptions.
parent
88065f16
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
2 deletions
+9
-2
trunk/src/ZODB/tests/testDB.py
trunk/src/ZODB/tests/testDB.py
+9
-2
No files found.
trunk/src/ZODB/tests/testDB.py
View file @
3ed59c28
...
...
@@ -14,6 +14,7 @@
import
os
import
time
import
unittest
import
warnings
import
ZODB
import
ZODB.FileStorage
...
...
@@ -48,9 +49,15 @@ class DBTests(unittest.TestCase):
def
testSets
(
self
):
# test set methods that have non-trivial implementations
self
.
db
.
setCacheDeactivateAfter
(
12
)
# deprecated
warnings
.
filterwarnings
(
"error"
,
category
=
DeprecationWarning
)
self
.
assertRaises
(
DeprecationWarning
,
self
.
db
.
setCacheDeactivateAfter
,
12
)
self
.
assertRaises
(
DeprecationWarning
,
self
.
db
.
setVersionCacheDeactivateAfter
,
12
)
# XXX There is no API call for removing the warning we just
# added, but filters appears to be a public variable.
del
warnings
.
filters
[
0
]
self
.
db
.
setCacheSize
(
15
)
self
.
db
.
setVersionCacheDeactivateAfter
(
12
)
# deprecated
self
.
db
.
setVersionCacheSize
(
15
)
def
test_removeVersionPool
(
self
):
...
...
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