Skip to content

Commit

Permalink
Fix it
Browse files Browse the repository at this point in the history
  • Loading branch information
palewire committed Mar 14, 2023
1 parent bad6aca commit 89ff764
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion bakery/tests/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,9 @@ def test_build_cmd(self):

def test_build_pathlib(self):
with self.settings(BUILD_DIR=Path(__file__).parent / "_dist"):
call_command("build", **{'skip_media': True, 'verbosity': 3})
call_command("build", **{'verbosity': 3})
with self.settings(STATIC_ROOT=Path(__file__).parent / "_static"):
call_command("build", **{'verbosity': 3})

def test_unbuild_cmd(self):
call_command("unbuild")
Expand Down
2 changes: 1 addition & 1 deletion bakery/views/detail.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def get_build_path(self, obj):
would like your detail page at a different location. By default it
will be built at get_url() + "index.html"
"""
target_path = path.join(settings.BUILD_DIR, self.get_url(obj).lstrip('/'))
target_path = path.join(str(settings.BUILD_DIR), self.get_url(obj).lstrip('/'))
if not self.fs.exists(target_path):
logger.debug("Creating {}".format(target_path))
self.fs.makedirs(target_path)
Expand Down

0 comments on commit 89ff764

Please sign in to comment.