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
5f8bb35f
Commit
5f8bb35f
authored
Jul 15, 2016
by
unawaz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Account settings page
unawaz/ECOM-4787-account-settings-page-header
parent
9f3b8ddf
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
0 deletions
+23
-0
lms/djangoapps/student_account/views.py
+1
-0
openedx/core/djangoapps/theming/tests/test_theme_style_overrides.py
+22
-0
No files found.
lms/djangoapps/student_account/views.py
View file @
5f8bb35f
...
...
@@ -436,6 +436,7 @@ def account_settings_context(request):
context
=
{
'auth'
:
{},
'duplicate_provider'
:
None
,
'nav_hidden'
:
True
,
'fields'
:
{
'country'
:
{
'options'
:
list
(
countries
),
...
...
openedx/core/djangoapps/theming/tests/test_theme_style_overrides.py
View file @
5f8bb35f
...
...
@@ -4,10 +4,12 @@
import
unittest
from
django.conf
import
settings
from
django.core.urlresolvers
import
reverse
from
django.test
import
TestCase
,
override_settings
from
django.contrib
import
staticfiles
from
openedx.core.djangoapps.theming.tests.test_util
import
with_comprehensive_theme
from
student.tests.factories
import
UserFactory
@unittest.skipUnless
(
settings
.
ROOT_URLCONF
==
'lms.urls'
,
'Test only valid in lms'
)
...
...
@@ -21,10 +23,15 @@ class TestComprehensiveThemeLMS(TestCase):
Clear static file finders cache and register cleanup methods.
"""
super
(
TestComprehensiveThemeLMS
,
self
)
.
setUp
()
self
.
user
=
UserFactory
()
# Clear the internal staticfiles caches, to get test isolation.
staticfiles
.
finders
.
get_finder
.
cache_clear
()
def
_login
(
self
):
""" Log into LMS. """
self
.
client
.
login
(
username
=
self
.
user
.
username
,
password
=
'test'
)
@with_comprehensive_theme
(
"test-theme"
)
def
test_footer
(
self
):
"""
...
...
@@ -35,6 +42,21 @@ class TestComprehensiveThemeLMS(TestCase):
# This string comes from header.html of test-theme
self
.
assertContains
(
resp
,
"This is a footer for test-theme."
)
@with_comprehensive_theme
(
"edx.org"
)
def
test_account_settings_hide_nav
(
self
):
"""
Test that theme header doesn't show marketing site links for Account Settings page.
"""
self
.
_login
()
account_settings_url
=
reverse
(
'account_settings'
)
response
=
self
.
client
.
get
(
account_settings_url
)
# Verify that the header navigation links are hidden for the edx.org version
self
.
assertNotContains
(
response
,
"How it Works"
)
self
.
assertNotContains
(
response
,
"Find courses"
)
self
.
assertNotContains
(
response
,
"Schools & Partners"
)
@with_comprehensive_theme
(
"test-theme"
)
def
test_logo_image
(
self
):
"""
...
...
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