Skip to content

Commit

Permalink
Merge pull request #52 from HECBioSim/issue47
Browse files Browse the repository at this point in the history
Issue #47
  • Loading branch information
jimboid committed Jun 12, 2017
2 parents 99b2724 + f8b7117 commit 8b3ceb9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion longbow/corelibs/entrypoints.py
Expand Up @@ -518,7 +518,7 @@ def _downloadexamples(longbowargs):
print("Extracting the archive file...")

subprocess.call(
["unzip", "-d", os.getcwd(),
["unzip", "-d", os.path.join(os.getcwd(), "longbow-examples/"),
os.path.join(os.getcwd(), "longbow-examples.zip")])

print("Removing the zip archive file...")
Expand Down
12 changes: 6 additions & 6 deletions tests/unit/corelibs_entrypoints/test_downloadexamples.py
Expand Up @@ -54,11 +54,11 @@ def test_downloadexamples_wget():

assert not os.path.isfile(
os.path.join(os.getcwd(), "longbow-examples.zip"))
assert os.path.isdir(os.path.join(os.getcwd(), "LongbowExamples/"))
assert os.path.isdir(os.path.join(os.getcwd(), "longbow-examples/"))

if os.path.isdir(os.path.join(os.getcwd(), "LongbowExamples/")):
if os.path.isdir(os.path.join(os.getcwd(), "longbow-examples/")):

shutil.rmtree(os.path.join(os.getcwd(), "LongbowExamples/"))
shutil.rmtree(os.path.join(os.getcwd(), "longbow-examples/"))


@mock.patch('subprocess.check_call')
Expand All @@ -78,8 +78,8 @@ def test_downloadexamples_curl(mock_check_call):

assert not os.path.isfile(
os.path.join(os.getcwd(), "longbow-examples.zip"))
assert os.path.isdir(os.path.join(os.getcwd(), "LongbowExamples/"))
assert os.path.isdir(os.path.join(os.getcwd(), "longbow-examples/"))

if os.path.isdir(os.path.join(os.getcwd(), "LongbowExamples/")):
if os.path.isdir(os.path.join(os.getcwd(), "longbow-examples/")):

shutil.rmtree(os.path.join(os.getcwd(), "LongbowExamples/"))
shutil.rmtree(os.path.join(os.getcwd(), "longbow-examples/"))

0 comments on commit 8b3ceb9

Please sign in to comment.