Commit 8bec4831 authored by Fred Drake's avatar Fred Drake

Two bugs:

- assertRaises() wasn't being called correctly
- test_warning() no longer applies
parent 78e35f93
...@@ -524,13 +524,13 @@ class test_mktemp(TC): ...@@ -524,13 +524,13 @@ class test_mktemp(TC):
for i in extant: for i in extant:
extant[i] = self.do_create(pre="aa") extant[i] = self.do_create(pre="aa")
def test_warning(self): ## def test_warning(self):
# mktemp issues a warning when used ## # mktemp issues a warning when used
warnings.filterwarnings("error", ## warnings.filterwarnings("error",
category=RuntimeWarning, ## category=RuntimeWarning,
message="mktemp") ## message="mktemp")
self.assertRaises(RuntimeWarning, ## self.assertRaises(RuntimeWarning,
tempfile.mktemp, (), { 'dir': self.dir }) ## tempfile.mktemp, dir=self.dir)
test_classes.append(test_mktemp) test_classes.append(test_mktemp)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment