[pypy-svn] r7661 - pypy/trunk/src/pypy/appspace/test
pedronis at codespeak.net
pedronis at codespeak.net
Wed Nov 24 17:52:37 CET 2004
Author: pedronis
Date: Wed Nov 24 17:52:36 2004
New Revision: 7661
Modified:
pypy/trunk/src/pypy/appspace/test/test_file.py
Log:
assertRaises takes callable+*args to do its job
here the test still fails because of the mapping 'w' -> os.O_WRONLY
btw /tmp/tt is a unixism
Modified: pypy/trunk/src/pypy/appspace/test/test_file.py
==============================================================================
--- pypy/trunk/src/pypy/appspace/test/test_file.py (original)
+++ pypy/trunk/src/pypy/appspace/test/test_file.py Wed Nov 24 17:52:36 2004
@@ -20,8 +20,7 @@
self.assertEquals(f.mode, 'w')
self.assertEquals(f.closed, False)
self.assertEquals(f.encoding, None) # Fix when we find out what this is
- self.assertRaises(TypeError, setattr(f, 'name', 42))
- #I am totally confused. This test fails, but a Type Error gets raised.
+ self.assertRaises(TypeError, setattr, f, 'name', 42)
def test_main():
unittest.main()
More information about the Pypy-commit
mailing list