mirror of
https://github.com/django/django.git
synced 2025-08-04 02:48:35 +00:00
Refs #23919 -- Replaced errno checking with PEP 3151 exceptions.
This commit is contained in:
parent
3f0c4fe18f
commit
632c4ffd9c
12 changed files with 55 additions and 87 deletions
2
tests/cache/tests.py
vendored
2
tests/cache/tests.py
vendored
|
@ -1360,7 +1360,7 @@ class FileBasedCacheTests(BaseCacheTests, TestCase):
|
|||
# Returns the default instead of erroring.
|
||||
self.assertEqual(cache.get('foo', 'baz'), 'baz')
|
||||
|
||||
def test_get_does_not_ignore_non_enoent_errno_values(self):
|
||||
def test_get_does_not_ignore_non_filenotfound_exceptions(self):
|
||||
with mock.patch('builtins.open', side_effect=IOError):
|
||||
with self.assertRaises(IOError):
|
||||
cache.get('foo')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue