Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
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
edx
edx-platform
Commits
3de366dc
Commit
3de366dc
authored
Sep 23, 2016
by
Jesse Zoldak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix pylint errors
parent
24ae284f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
+9
-3
common/lib/capa/capa/tests/helpers.py
+9
-3
No files found.
common/lib/capa/capa/tests/helpers.py
View file @
3de366dc
...
...
@@ -33,7 +33,7 @@ def capa_render_template(template, context):
return
get_template
(
template
)
.
render_unicode
(
**
context
)
def
tst_render_template
(
template
,
context
):
def
tst_render_template
(
template
,
context
):
# pylint: disable=unused-argument
"""
A test version of render to template. Renders to the repr of the context, completely ignoring
the template name. To make the output valid xml, quotes the content, and wraps it in a <div>
...
...
@@ -42,9 +42,10 @@ def tst_render_template(template, context):
def
calledback_url
(
dispatch
=
'score_update'
):
"""A callback url method to use in tests."""
return
dispatch
xqueue_interface
=
MagicMock
()
xqueue_interface
=
MagicMock
()
# pylint: disable=invalid-name
xqueue_interface
.
send_to_queue
.
return_value
=
(
0
,
'Success!'
)
...
...
@@ -68,7 +69,12 @@ def test_capa_system(render_template=None):
seed
=
0
,
STATIC_URL
=
'/dummy-static/'
,
STATUS_CLASS
=
Status
,
xqueue
=
{
'interface'
:
xqueue_interface
,
'construct_callback'
:
calledback_url
,
'default_queuename'
:
'testqueue'
,
'waittime'
:
10
},
xqueue
=
{
'interface'
:
xqueue_interface
,
'construct_callback'
:
calledback_url
,
'default_queuename'
:
'testqueue'
,
'waittime'
:
10
},
)
return
the_system
...
...
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