summaryrefslogtreecommitdiff
path: root/Lib/test/test_extcall.py
diff options
context:
space:
mode:
authorMarc-André Lemburg <mal@egenix.com>2001-01-17 19:11:13 +0000
committerMarc-André Lemburg <mal@egenix.com>2001-01-17 19:11:13 +0000
commit3661908a6ac75026e4504d9f62a6ac2e2fb2ec5e (patch)
treeeea0f44df59aaaf014eb4580f1fad308e31601bf /Lib/test/test_extcall.py
parent8551dd60781f738e5e5ef4e22b6f071d27e20b50 (diff)
downloadcpython-git-3661908a6ac75026e4504d9f62a6ac2e2fb2ec5e.tar.gz
This patch removes all uses of "assert" in the regression test suite
and replaces them with a new API verify(). As a result the regression suite will also perform its tests in optimization mode. Written by Marc-Andre Lemburg. Copyright assigned to Guido van Rossum.
Diffstat (limited to 'Lib/test/test_extcall.py')
-rw-r--r--Lib/test/test_extcall.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/Lib/test/test_extcall.py b/Lib/test/test_extcall.py
index b53ced7503..5b6c5ec369 100644
--- a/Lib/test/test_extcall.py
+++ b/Lib/test/test_extcall.py
@@ -1,3 +1,4 @@
+from test_support import verify, verbose
from UserList import UserList
from test_support import TestFailed
import string
@@ -79,11 +80,11 @@ g(*Nothing())
# make sure the function call doesn't stomp on the dictionary?
d = {'a': 1, 'b': 2, 'c': 3}
d2 = d.copy()
-assert d == d2
+verify(d == d2)
g(1, d=4, **d)
print d
print d2
-assert d == d2, "function call modified dictionary"
+verify(d == d2, "function call modified dictionary")
# what about willful misconduct?
def saboteur(**kw):
@@ -91,7 +92,7 @@ def saboteur(**kw):
return kw
d = {}
kw = saboteur(a=1, **d)
-assert d == {}
+verify(d == {})
# break the cycle
del kw['x']