Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-ora2
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-ora2
Commits
6c60344f
Commit
6c60344f
authored
Dec 07, 2015
by
Diana Huang
Committed by
Andy Armstrong
Dec 15, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename the 'Staff Tools' and 'Staff Info' buttons.
parent
e601a79d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
17 deletions
+17
-17
openassessment/templates/openassessmentblock/staff_area/oa_staff_area.html
+2
-2
openassessment/xblock/static/js/spec/lms/oa_staff_area.js
+7
-7
test/acceptance/tests.py
+8
-8
No files found.
openassessment/templates/openassessmentblock/staff_area/oa_staff_area.html
View file @
6c60344f
...
...
@@ -3,8 +3,8 @@
<div
class=
"openassessment__staff-area wrapper--staff-area"
>
<div
class=
"wrapper--staff-toolbar"
>
<button
class=
"ui-staff__button button-staff-tools"
data-panel=
"openassessment__staff-tools"
>
{% trans "
Staff Tool
s" %}
</button>
<button
class=
"ui-staff__button button-staff-info"
data-panel=
"openassessment__staff-info"
>
{% trans "
Staff Info
" %}
</button>
<button
class=
"ui-staff__button button-staff-tools"
data-panel=
"openassessment__staff-tools"
>
{% trans "
Manage Individual Learner
s" %}
</button>
<button
class=
"ui-staff__button button-staff-info"
data-panel=
"openassessment__staff-info"
>
{% trans "
View Assignment Statistics
" %}
</button>
</div>
<div
class=
"openassessment__staff-tools wrapper--staff-tools wrapper--ui-staff is--hidden"
>
...
...
openassessment/xblock/static/js/spec/lms/oa_staff_area.js
View file @
6c60344f
...
...
@@ -205,22 +205,22 @@ describe('OpenAssessment.StaffAreaView', function() {
var
view
=
createStaffArea
(),
$buttons
=
$
(
'.ui-staff__button'
,
view
.
element
);
expect
(
$buttons
.
length
).
toBe
(
2
);
expect
(
$
(
$buttons
[
0
]).
text
().
trim
()).
toEqual
(
'
Staff Tool
s'
);
expect
(
$
(
$buttons
[
1
]).
text
().
trim
()).
toEqual
(
'
Staff Info
'
);
expect
(
$
(
$buttons
[
0
]).
text
().
trim
()).
toEqual
(
'
Manage Individual Learner
s'
);
expect
(
$
(
$buttons
[
1
]).
text
().
trim
()).
toEqual
(
'
View Assignment Statistics
'
);
expect
(
getVisibleStaffPanels
(
view
).
length
).
toBe
(
0
);
});
it
(
'shows the "
Staff Tool
s" panel when the button is clicked'
,
function
()
{
it
(
'shows the "
Manage Individual Learner
s" panel when the button is clicked'
,
function
()
{
var
view
=
createStaffArea
();
verifyStaffButtonBehavior
(
view
,
'staff-tools'
);
});
it
(
'shows the "
Staff Info
" panel when the button is clicked'
,
function
()
{
it
(
'shows the "
View Assignment Statistics
" panel when the button is clicked'
,
function
()
{
var
view
=
createStaffArea
();
verifyStaffButtonBehavior
(
view
,
'staff-info'
);
});
it
(
'hides the "
Staff Tool
s" panel when the button is clicked twice'
,
function
()
{
it
(
'hides the "
Manage Individual Learner
s" panel when the button is clicked twice'
,
function
()
{
var
view
=
createStaffArea
(),
$staffToolsButton
=
getStaffButton
(
view
,
'staff-tools'
);
expect
(
$staffToolsButton
).
not
.
toHaveClass
(
'is--active'
);
...
...
@@ -244,7 +244,7 @@ describe('OpenAssessment.StaffAreaView', function() {
loadFixtures
(
'oa_base_course_staff.html'
);
});
it
(
'hides the "
Staff Tool
s" panel when the close button is clicked'
,
function
()
{
it
(
'hides the "
Manage Individual Learner
s" panel when the close button is clicked'
,
function
()
{
var
view
=
createStaffArea
(),
$staffToolsButton
=
$
(
'.button-staff-tools'
,
view
.
element
),
$staffToolsPanel
=
$
(
'.wrapper--staff-tools'
,
view
.
element
);
...
...
@@ -400,7 +400,7 @@ describe('OpenAssessment.StaffAreaView', function() {
loadFixtures
(
'oa_base_course_staff.html'
);
});
it
(
'hides the "
Staff Info
" panel when the close button is clicked'
,
function
()
{
it
(
'hides the "
View Assignment Statistics
" panel when the close button is clicked'
,
function
()
{
var
view
=
createStaffArea
(),
$staffInfoButton
=
$
(
'.button-staff-info'
,
view
.
element
),
$staffInfoPanel
=
$
(
'.wrapper--staff-info'
,
view
.
element
);
...
...
test/acceptance/tests.py
View file @
6c60344f
...
...
@@ -313,10 +313,10 @@ class StaffAreaTest(OpenAssessmentTest):
Given I am viewing the staff area of an ORA problem
Then none of the buttons should be active
When I click the "
Staff Tool
s" button
Then only the "
Staff Tool
s" button should be active
When I click the "
Staff Info
" button
Then only the "
Staff Info
" button should be active
When I click the "
Manage Individual Learner
s" button
Then only the "
Manage Individual Learner
s" button should be active
When I click the "
View Assignment Statistics
" button
Then only the "
View Assignment Statistics
" button should be active
When I click the "Staff Info" button again
Then none of the buttons should be active
"""
...
...
@@ -324,17 +324,17 @@ class StaffAreaTest(OpenAssessmentTest):
self
.
staff_area_page
.
visit
()
self
.
assertEqual
(
self
.
staff_area_page
.
selected_button_names
,
[])
self
.
staff_area_page
.
click_staff_toolbar_button
(
"staff-tools"
)
self
.
assertEqual
(
self
.
staff_area_page
.
selected_button_names
,
[
"
STAFF TOOL
S"
])
self
.
assertEqual
(
self
.
staff_area_page
.
selected_button_names
,
[
"
MANAGE INDIVIDUAL LEARNER
S"
])
self
.
staff_area_page
.
click_staff_toolbar_button
(
"staff-info"
)
self
.
assertEqual
(
self
.
staff_area_page
.
selected_button_names
,
[
"
STAFF INFO
"
])
self
.
assertEqual
(
self
.
staff_area_page
.
selected_button_names
,
[
"
VIEW ASSIGNMENT STATISTICS
"
])
self
.
staff_area_page
.
click_staff_toolbar_button
(
"staff-info"
)
self
.
assertEqual
(
self
.
staff_area_page
.
selected_button_names
,
[])
@retry
()
@attr
(
'acceptance'
)
@ddt.data
(
(
"staff-tools"
,
"
STAFF TOOL
S"
),
(
"staff-info"
,
"
STAFF INFO
"
),
(
"staff-tools"
,
"
MANAGE INDIVIDUAL LEARNER
S"
),
(
"staff-info"
,
"
VIEW ASSIGNMENT STATISTICS
"
),
)
@ddt.unpack
def
test_staff_area_panel
(
self
,
panel_name
,
button_label
):
...
...
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