Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
d0a1762a
Commit
d0a1762a
authored
Apr 15, 2002
by
Tim Peters
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reduce the number of test-suite DeprecationWarnings; start adding
resetwarnings() calls too.
parent
19841eda
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
3 deletions
+12
-3
Lib/test/test___all__.py
Lib/test/test___all__.py
+2
-0
Lib/test/test_coercion.py
Lib/test/test_coercion.py
+9
-2
Lib/test/test_xmllib.py
Lib/test/test_xmllib.py
+1
-1
No files found.
Lib/test/test___all__.py
View file @
d0a1762a
...
...
@@ -158,3 +158,5 @@ check_all("weakref")
check_all
(
"webbrowser"
)
check_all
(
"xdrlib"
)
check_all
(
"zipfile"
)
warnings
.
resetwarnings
()
Lib/test/test_coercion.py
View file @
d0a1762a
import
copy
import
sys
import
warnings
# Fake a number that implements numeric methods through __coerce__
class
CoerceNumber
:
...
...
@@ -109,5 +110,11 @@ def do_prefix_binops():
else
:
print
'='
,
x
do_infix_binops
()
do_prefix_binops
()
warnings
.
filterwarnings
(
"ignore"
,
r'complex divmod\
(
\), // and % are deprecated'
,
DeprecationWarning
)
try
:
do_infix_binops
()
do_prefix_binops
()
finally
:
warnings
.
resetwarnings
()
Lib/test/test_xmllib.py
View file @
d0a1762a
...
...
@@ -16,7 +16,6 @@ testdoc = """\
import
warnings
warnings
.
filterwarnings
(
"ignore"
,
".* xmllib .* obsolete.*"
,
DeprecationWarning
)
del
warnings
import
test_support
import
unittest
...
...
@@ -33,6 +32,7 @@ class XMLParserTestCase(unittest.TestCase):
def
test_main
():
test_support
.
run_unittest
(
XMLParserTestCase
)
warnings
.
resetwarnings
()
if
__name__
==
"__main__"
:
...
...
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