diff options
author | zeyneloz <ozdemir.zynl@gmail.com> | 2019-08-02 08:16:42 +0200 |
---|---|---|
committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2019-08-02 08:35:25 +0200 |
commit | 246689452d33ff0dbf8e28b6948b23261083b187 (patch) | |
tree | 0449fd145314c3d37fa3e5bd122e00cc4c1cd7f5 /tests/staticfiles_tests | |
parent | d14fa04ab398e77e6f19b0453af4183b5e4cd14e (diff) | |
download | django-246689452d33ff0dbf8e28b6948b23261083b187.tar.gz |
Added test for handling of non-existent manifest in ManifestFilesMixin.read_manifest().
Diffstat (limited to 'tests/staticfiles_tests')
-rw-r--r-- | tests/staticfiles_tests/test_storage.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/staticfiles_tests/test_storage.py b/tests/staticfiles_tests/test_storage.py index 51dbf6f4b9..59ed734704 100644 --- a/tests/staticfiles_tests/test_storage.py +++ b/tests/staticfiles_tests/test_storage.py @@ -385,6 +385,10 @@ class TestCollectionManifestStorage(TestHashedFiles, CollectionTestCase): path = storage.staticfiles_storage.path(filename) self.assertTrue(os.path.exists(path)) + def test_manifest_does_not_exist(self): + storage.staticfiles_storage.manifest_name = 'does.not.exist.json' + self.assertIsNone(storage.staticfiles_storage.read_manifest()) + def test_loaded_cache(self): self.assertNotEqual(storage.staticfiles_storage.hashed_files, {}) manifest_content = storage.staticfiles_storage.read_manifest() |