diff options
| author | za <za@python.or.id> | 2016-10-27 14:53:39 +0700 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2016-11-10 21:30:21 -0500 |
| commit | 321e94fa41b121f65c02119c02098df327bbd569 (patch) | |
| tree | ce5476c191d589aca4b124f841dfbccac8dd299f /tests/file_storage | |
| parent | 4bb70cbcc60794f515c9bfefeca87b8272d33c0c (diff) | |
Refs #27392 -- Removed "Tests that", "Ensures that", etc. from test docstrings.
Diffstat (limited to 'tests/file_storage')
| -rw-r--r-- | tests/file_storage/tests.py | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/tests/file_storage/tests.py b/tests/file_storage/tests.py index 5492f105f7..422435518e 100644 --- a/tests/file_storage/tests.py +++ b/tests/file_storage/tests.py @@ -161,7 +161,7 @@ class FileStorageTests(SimpleTestCase): self.assertTrue(timezone.is_aware(dt)) self.assertEqual(now.tzname(), dt.tzname()) - # Check that the three timezones are indeed distinct. + # The three timezones are indeed distinct. naive_now = datetime.now() algiers_offset = now_in_algiers.tzinfo.utcoffset(naive_now) django_offset = timezone.get_current_timezone().utcoffset(naive_now) @@ -192,7 +192,7 @@ class FileStorageTests(SimpleTestCase): # dt should be naive, in system (+1) TZ self.assertTrue(timezone.is_naive(dt)) - # Check that the three timezones are indeed distinct. + # The three timezones are indeed distinct. naive_now = datetime.now() algiers_offset = now_in_algiers.tzinfo.utcoffset(naive_now) django_offset = timezone.get_current_timezone().utcoffset(naive_now) @@ -484,7 +484,7 @@ class FileStorageTests(SimpleTestCase): with self.storage.open('raced/test.file') as f: self.assertEqual(f.read(), b'saved with race') - # Check that OSErrors aside from EEXIST are still raised. + # OSErrors aside from EEXIST are still raised. with self.assertRaises(OSError): self.storage.save('error/test.file', ContentFile('not saved')) finally: @@ -520,7 +520,7 @@ class FileStorageTests(SimpleTestCase): self.storage.delete('raced.file') self.assertFalse(self.storage.exists('normal.file')) - # Check that OSErrors aside from ENOENT are still raised. + # OSErrors aside from ENOENT are still raised. self.storage.save('error.file', ContentFile('delete with error')) with self.assertRaises(OSError): self.storage.delete('error.file') @@ -988,8 +988,9 @@ class ContentFileStorageTestCase(unittest.TestCase): def test_content_saving(self): """ - Test that ContentFile can be saved correctly with the filesystem storage, - both if it was initialized with string or unicode content""" + ContentFile can be saved correctly with the filesystem storage, + if it was initialized with either bytes or unicode content. + """ self.storage.save('bytes.txt', ContentFile(b"content")) self.storage.save('unicode.txt', ContentFile("espaƱol")) |
