mirror of
https://github.com/django/django.git
synced 2025-11-25 21:22:14 +00:00
PEP8 cleanup
Signed-off-by: Jason Myers <jason@jasonamyers.com>
This commit is contained in:
parent
0fdb692c6c
commit
7a61c68c50
128 changed files with 739 additions and 206 deletions
|
|
@ -69,6 +69,7 @@ class GetStorageClassTests(SimpleTestCase):
|
|||
get_storage_class(
|
||||
'django.core.files.non_existing_storage.NonExistingStorage')
|
||||
|
||||
|
||||
class FileStorageTests(unittest.TestCase):
|
||||
storage_class = FileSystemStorage
|
||||
|
||||
|
|
@ -379,6 +380,7 @@ class CustomStorage(FileSystemStorage):
|
|||
|
||||
return name
|
||||
|
||||
|
||||
class CustomStorageTests(FileStorageTests):
|
||||
storage_class = CustomStorage
|
||||
|
||||
|
|
@ -531,6 +533,7 @@ class SlowFile(ContentFile):
|
|||
time.sleep(1)
|
||||
return super(ContentFile, self).chunks()
|
||||
|
||||
|
||||
class FileSaveRaceConditionTest(unittest.TestCase):
|
||||
def setUp(self):
|
||||
self.storage_dir = tempfile.mkdtemp()
|
||||
|
|
@ -552,6 +555,7 @@ class FileSaveRaceConditionTest(unittest.TestCase):
|
|||
self.storage.delete('conflict')
|
||||
self.storage.delete('conflict_1')
|
||||
|
||||
|
||||
@unittest.skipIf(sys.platform.startswith('win'), "Windows only partially supports umasks and chmod.")
|
||||
class FileStoragePermissions(unittest.TestCase):
|
||||
def setUp(self):
|
||||
|
|
@ -591,6 +595,7 @@ class FileStoragePermissions(unittest.TestCase):
|
|||
dir_mode = os.stat(os.path.dirname(self.storage.path(name)))[0] & 0o777
|
||||
self.assertEqual(dir_mode, 0o777 & ~self.umask)
|
||||
|
||||
|
||||
class FileStoragePathParsing(unittest.TestCase):
|
||||
def setUp(self):
|
||||
self.storage_dir = tempfile.mkdtemp()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue