Skip to content

Commit

Permalink
Fix #5911: comments and cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
gurhar1133 committed Jul 31, 2023
1 parent 5384195 commit 5b66488
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions sirepo/resource.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,16 +54,16 @@ def render_jinja(*paths, target_dir=None, j2_ctx=None):
j2_ctx (PKDict): parameters to jinja file
Returns:
py.path: path to rendered file
py.path: output path which is target_dir.join(paths[-1])
"""
f = paths[-1]
t = target_dir.join(f)
res = target_dir.join(f)
pykern.pkjinja.render_file(
file_path(*paths[:-1], f + pykern.pkjinja.RESOURCE_SUFFIX),
j2_ctx,
output=t,
output=res,
)
return t
return res


def root_modules():
Expand Down
2 changes: 1 addition & 1 deletion tests/resource_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
:license: http://www.apache.org/licenses/LICENSE-2.0.html
"""
import pytest
from pykern.pkcollections import PKDict


def test_static_files():
Expand All @@ -22,6 +21,7 @@ def test_static_files():

def test_render_resource():
from sirepo import resource
from pykern.pkcollections import PKDict
from pykern import pkunit
from pykern import pkio

Expand Down

0 comments on commit 5b66488

Please sign in to comment.