mirror of
https://github.com/django/django.git
synced 2025-08-03 18:38:50 +00:00
Refs #30160 -- Made destination path a required argument of extract().
This commit is contained in:
parent
c7bef16a74
commit
0509148c24
2 changed files with 2 additions and 13 deletions
|
@ -33,12 +33,6 @@ class ArchiveTester:
|
|||
archive.extract(self.tmpdir)
|
||||
self.check_files(self.tmpdir)
|
||||
|
||||
def test_extract_method_no_to_path(self):
|
||||
os.chdir(self.tmpdir)
|
||||
with Archive(self.archive_path) as archive:
|
||||
archive.extract()
|
||||
self.check_files(self.tmpdir)
|
||||
|
||||
def test_extract_function(self):
|
||||
extract(self.archive_path, self.tmpdir)
|
||||
self.check_files(self.tmpdir)
|
||||
|
@ -59,11 +53,6 @@ class ArchiveTester:
|
|||
extract(self.archive_lead_path, self.tmpdir)
|
||||
self.check_files(self.tmpdir)
|
||||
|
||||
def test_extract_function_no_to_path(self):
|
||||
os.chdir(self.tmpdir)
|
||||
extract(self.archive_path)
|
||||
self.check_files(self.tmpdir)
|
||||
|
||||
def check_files(self, tmpdir):
|
||||
self.assertTrue(os.path.isfile(os.path.join(self.tmpdir, '1')))
|
||||
self.assertTrue(os.path.isfile(os.path.join(self.tmpdir, '2')))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue