Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gelencsér Szabolcs
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
a43c9ead
authored
May 07, 2015
by
Kálmán Viktor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboard: fix template tester test
parent
0aa83f04
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
5 deletions
+3
-5
circle/dashboard/tests/test_templates.py
+3
-5
No files found.
circle/dashboard/tests/test_templates.py
View file @
a43c9ead
...
@@ -19,9 +19,8 @@ from os import listdir
...
@@ -19,9 +19,8 @@ from os import listdir
from
os.path
import
isfile
,
isdir
,
join
from
os.path
import
isfile
,
isdir
,
join
import
unittest
import
unittest
from
django.conf
import
settings
from
django.template
import
Template
,
Context
,
VariableDoesNotExist
from
django.template
import
Template
,
Context
,
VariableDoesNotExist
from
django.template.
loader
import
find_template_loader
from
django.template.
engine
import
Engine
from
django.core.urlresolvers
import
NoReverseMatch
from
django.core.urlresolvers
import
NoReverseMatch
...
@@ -29,9 +28,8 @@ class TemplateSyntaxTestCase(unittest.TestCase):
...
@@ -29,9 +28,8 @@ class TemplateSyntaxTestCase(unittest.TestCase):
def
test_templates
(
self
):
def
test_templates
(
self
):
"""Test all templates for syntax errors."""
"""Test all templates for syntax errors."""
for
loader_name
in
settings
.
TEMPLATE_LOADERS
:
for
loader
in
Engine
.
get_default
()
.
template_loaders
:
print
loader_name
print
loader
loader
=
find_template_loader
(
loader_name
)
self
.
_test_dir
(
loader
.
get_template_sources
(
''
))
self
.
_test_dir
(
loader
.
get_template_sources
(
''
))
def
_test_dir
(
self
,
dir
,
path
=
"/"
):
def
_test_dir
(
self
,
dir
,
path
=
"/"
):
...
...
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