Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
pystache_custom
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
pystache_custom
Commits
dcb78dd6
Commit
dcb78dd6
authored
Mar 22, 2012
by
Chris Jerdonek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Renamed custom Loader constructor parameter from template_locator to locator.
parent
d5ee38b6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
6 deletions
+5
-6
pystache/custom_template.py
+4
-5
tests/test_custom_template.py
+1
-1
No files found.
pystache/custom_template.py
View file @
dcb78dd6
...
...
@@ -126,18 +126,17 @@ class Loader(object):
"""
# TODO: rename template_locator to locator.
def
__init__
(
self
,
search_dirs
,
template_locator
=
None
,
reader
=
None
):
def
__init__
(
self
,
search_dirs
,
locator
=
None
,
reader
=
None
):
if
reader
is
None
:
reader
=
Reader
()
if
template_
locator
is
None
:
template_
locator
=
TemplateLocator
()
if
locator
is
None
:
locator
=
TemplateLocator
()
self
.
reader
=
reader
self
.
search_dirs
=
search_dirs
# TODO: rename this to locator.
self
.
template_locator
=
template_
locator
self
.
template_locator
=
locator
# TODO: make this private.
def
get_relative_template_location
(
self
,
view
):
...
...
tests/test_custom_template.py
View file @
dcb78dd6
...
...
@@ -177,7 +177,7 @@ class LoaderTests(unittest.TestCase, AssertIsMixin):
def
test_init__locator
(
self
):
locator
=
Locator
()
loader
=
Loader
([],
template_
locator
=
locator
)
loader
=
Loader
([],
locator
=
locator
)
self
.
assertIs
(
loader
.
template_locator
,
locator
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment