(original) (raw)

changeset: 76786:4d74d275224d user: Vinay Sajip <vinay_sajip@yahoo.co.uk> date: Sun May 06 11:34:50 2012 +0100 files: Lib/test/test_capi.py description: Issue #9116: Allowed test to pass on Windows by adjusting the test condition slightly to allow for a Windows-specific error message. diff -r 2e71f25912d4 -r 4d74d275224d Lib/test/test_capi.py --- a/Lib/test/test_capi.py Sun May 06 11:28:46 2012 +0100 +++ b/Lib/test/test_capi.py Sun May 06 11:34:50 2012 +0100 @@ -48,9 +48,9 @@ (out, err) = p.communicate() self.assertEqual(out, b'') # This used to cause an infinite loop. - self.assertEqual(err.rstrip(), + self.assertTrue(err.rstrip().startswith( b'Fatal Python error:' - b' PyThreadState_Get: no current thread') + b' PyThreadState_Get: no current thread')) def test_memoryview_from_NULL_pointer(self): self.assertRaises(ValueError, _testcapi.make_memoryview_from_NULL_pointer) </vinay_sajip@yahoo.co.uk>