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
3468ca34
Commit
3468ca34
authored
Dec 12, 2016
by
Mark Sadecki
Committed by
GitHub
Dec 12, 2016
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #14121 from edx/cptvitamin/AC-680
removes redundant alt attribute value
parents
388ed865
33949571
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
1 deletions
+12
-1
common/test/acceptance/pages/lms/dashboard.py
+4
-0
common/test/acceptance/tests/lms/test_lms_dashboard.py
+7
-0
lms/templates/user_dropdown.html
+1
-1
No files found.
common/test/acceptance/pages/lms/dashboard.py
View file @
3468ca34
...
...
@@ -156,6 +156,10 @@ class DashboardPage(PageObject):
""" Retrieves the specified social sharing widget by its classification """
return
self
.
q
(
css
=
'a.action-{}'
.
format
(
widget_name
))
def
get_profile_img
(
self
):
""" Retrieves the user's profile image """
return
self
.
q
(
css
=
'img.user-image-frame'
)
def
get_courses
(
self
):
"""
Get all courses shown in the dashboard
...
...
common/test/acceptance/tests/lms/test_lms_dashboard.py
View file @
3468ca34
...
...
@@ -305,6 +305,13 @@ class LmsDashboardPageTest(BaseLmsDashboardTest):
# and course starts within 5 days
self
.
assertEqual
(
course_date
,
expected_course_date
)
def
test_profile_img_alt_empty
(
self
):
"""
Validate value of profile image alt attribue is null
"""
profile_img
=
self
.
dashboard_page
.
get_profile_img
()
self
.
assertEqual
(
profile_img
.
attrs
(
'alt'
)[
0
],
''
)
@attr
(
'a11y'
)
class
LmsDashboardA11yTest
(
BaseLmsDashboardTestMultiple
):
...
...
lms/templates/user_dropdown.html
View file @
3468ca34
...
...
@@ -49,7 +49,7 @@ from openedx.core.djangoapps.user_api.accounts.image_helpers import get_profile_
username =
self.real_user.username
profile_image_url =
get_profile_image_urls_for_user(self.real_user)['medium']
%
>
<img
class=
"user-image-frame"
src=
"${profile_image_url}"
alt=
"
${_('Profile image for {username}').format(username=username)}
"
>
<img
class=
"user-image-frame"
src=
"${profile_image_url}"
alt=
""
>
<div
class=
"label-username"
>
${username}
</div>
</a>
</li>
...
...
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