diff options
author | Collin Winter <collinw@gmail.com> | 2007-08-30 03:47:13 (GMT) |
---|---|---|
committer | Collin Winter <collinw@gmail.com> | 2007-08-30 03:47:13 (GMT) |
commit | a73bfee73da519a508e7d95bc55c1984ae7089bd (patch) | |
tree | 0dc90296a87672d7634e2f11890bf0c0dfd77031 /Lib/ctypes/test | |
parent | 9604e66660bfe5066a88e3eb560a5846c620e8de (diff) | |
download | cpython-a73bfee73da519a508e7d95bc55c1984ae7089bd.zip cpython-a73bfee73da519a508e7d95bc55c1984ae7089bd.tar.gz cpython-a73bfee73da519a508e7d95bc55c1984ae7089bd.tar.bz2 |
Raise statement normalization in Lib/ctypes/.
Diffstat (limited to 'Lib/ctypes/test')
-rw-r--r-- | Lib/ctypes/test/test_cfuncs.py | 2 | ||||
-rw-r--r-- | Lib/ctypes/test/test_macholib.py | 2 | ||||
-rw-r--r-- | Lib/ctypes/test/test_random_things.py | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/Lib/ctypes/test/test_cfuncs.py b/Lib/ctypes/test/test_cfuncs.py index fa858a6..63564a8 100644 --- a/Lib/ctypes/test/test_cfuncs.py +++ b/Lib/ctypes/test/test_cfuncs.py @@ -186,7 +186,7 @@ else: class stdcall_dll(WinDLL): def __getattr__(self, name): if name[:2] == '__' and name[-2:] == '__': - raise AttributeError, name + raise AttributeError(name) func = self._FuncPtr(("s_" + name, self)) setattr(self, name, func) return func diff --git a/Lib/ctypes/test/test_macholib.py b/Lib/ctypes/test/test_macholib.py index 4bb68ac..f2ee035 100644 --- a/Lib/ctypes/test/test_macholib.py +++ b/Lib/ctypes/test/test_macholib.py @@ -42,7 +42,7 @@ def find_lib(name): return os.path.realpath(dyld_find(dylib)) except ValueError: pass - raise ValueError, "%s not found" % (name,) + raise ValueError("%s not found" % (name,)) class MachOTest(unittest.TestCase): if sys.platform == "darwin": diff --git a/Lib/ctypes/test/test_random_things.py b/Lib/ctypes/test/test_random_things.py index e803895..6b2c1b1 100644 --- a/Lib/ctypes/test/test_random_things.py +++ b/Lib/ctypes/test/test_random_things.py @@ -3,7 +3,7 @@ import unittest, sys def callback_func(arg): 42 / arg - raise ValueError, arg + raise ValueError(arg) if sys.platform == "win32": |