Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
87d78241
Kaydet (Commit)
87d78241
authored
Mar 07, 2015
tarafından
Sztrovacsek
Kaydeden (comit)
Tim Graham
Mar 07, 2015
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed #23986 -- Fixed collectstatic --clear failure if STATIC_ROOT dir doesn't exist.
üst
90b069c3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
0 deletions
+7
-0
collectstatic.py
.../contrib/staticfiles/management/commands/collectstatic.py
+3
-0
tests.py
tests/staticfiles_tests/tests.py
+4
-0
No files found.
django/contrib/staticfiles/management/commands/collectstatic.py
Dosyayı görüntüle @
87d78241
...
...
@@ -199,6 +199,9 @@ class Command(BaseCommand):
"""
Deletes the given relative path using the destination storage backend.
"""
if
not
self
.
storage
.
exists
(
path
):
return
dirs
,
files
=
self
.
storage
.
listdir
(
path
)
for
f
in
files
:
fpath
=
os
.
path
.
join
(
path
,
f
)
...
...
tests/staticfiles_tests/tests.py
Dosyayı görüntüle @
87d78241
...
...
@@ -301,6 +301,10 @@ class TestCollectionClear(CollectionTestCase):
def
test_cleared_not_found
(
self
):
self
.
assertFileNotFound
(
'cleared.txt'
)
def
test_dir_not_exists
(
self
,
**
kwargs
):
shutil
.
rmtree
(
settings
.
STATIC_ROOT
)
super
(
TestCollectionClear
,
self
)
.
run_collectstatic
(
clear
=
True
)
class
TestCollectionExcludeNoDefaultIgnore
(
CollectionTestCase
,
TestDefaults
):
"""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment