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
b6c00810
Commit
b6c00810
authored
May 16, 2013
by
Diana Huang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Look for the existence of the links, not for
the actual urls
parent
22cf0dfa
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
20 deletions
+22
-20
common/djangoapps/terrain/steps.py
+7
-0
lms/djangoapps/courseware/features/homepage.feature
+10
-15
lms/templates/footer.html
+5
-5
No files found.
common/djangoapps/terrain/steps.py
View file @
b6c00810
...
...
@@ -122,6 +122,13 @@ def should_see_a_link_called(step, text):
assert
len
(
world
.
browser
.
find_link_by_text
(
text
))
>
0
@step
(
r'should see (?:the|a) link with the id "([^"]*)" called "([^"]*)"$'
)
def
should_have_link_with_id_and_text
(
step
,
link_id
,
text
):
link
=
world
.
browser
.
find_by_id
(
link_id
)
assert
len
(
link
)
>
0
assert_equals
(
link
.
text
,
text
)
@step
(
r'should see "(.*)" (?:somewhere|anywhere) in (?:the|this) page'
)
def
should_see_in_the_page
(
step
,
text
):
assert_in
(
text
,
world
.
css_text
(
'body'
))
...
...
lms/djangoapps/courseware/features/homepage.feature
View file @
b6c00810
...
...
@@ -5,29 +5,24 @@ Feature: Homepage for web users
Scenario
:
User can see the "Login" button
Given
I visit the homepage
Then
I should see a link called
"Log
I
n"
Then
I should see a link called
"Log
i
n"
Scenario
:
User can see the "
Sign up
" button
Scenario
:
User can see the "
Register Now
" button
Given
I visit the homepage
Then
I should see a link called
"
Sign Up
"
Then
I should see a link called
"
Register Now
"
Scenario Outline
:
User can see main parts of the page
Given
I visit the homepage
Then
I should see a link called
"<Link>"
When
I click the link with the text
"<Link>"
Then
I should see that the path is
"<Path>"
Then
I should see a link with the id
"<id>"
called
"<Link>"
Examples
:
|
Link
|
Path
|
|
Find
Courses
|
/courses
|
|
About
|
/about
|
|
Jobs
|
/jobs
|
|
Contact
|
/contact
|
|
id
|
Link
|
|
about
|
About
|
|
jobs
|
Jobs
|
|
faq
|
FAQ
|
|
contact
|
Contact
|
|
press
|
Press
|
Scenario
:
User can visit the blog
Given
I visit the homepage
When
I click the link with the text
"Blog"
Then I should see that the url is "http
:
//blog.edx.org/"
# TODO: test according to domain or policy
Scenario
:
User can see the partner institutions
...
...
lms/templates/footer.html
View file @
b6c00810
...
...
@@ -8,27 +8,27 @@
<nav
class=
"nav-colophon"
>
<ol>
<li
class=
"nav-colophon-01"
>
<a
href=
"${marketing_link('ABOUT')}"
>
<a
id=
"about"
href=
"${marketing_link('ABOUT')}"
>
About
</a>
</li>
<li
class=
"nav-colophon-02"
>
<a
href=
"${marketing_link('JOBS')}"
>
<a
id=
"jobs"
href=
"${marketing_link('JOBS')}"
>
Jobs
</a>
</li>
<li
class=
"nav-colophon-03"
>
<a
href=
"${marketing_link('PRESS')}"
>
<a
id=
"press"
href=
"${marketing_link('PRESS')}"
>
Press
</a>
</li>
<li
class=
"nav-colophon-04"
>
<a
href=
"${marketing_link('FAQ')}"
>
<a
id=
"faq"
href=
"${marketing_link('FAQ')}"
>
FAQ
</a>
</li>
<li
class=
"nav-colophon-05"
>
<a
href=
"${marketing_link('CONTACT')}"
>
<a
id=
"contact"
href=
"${marketing_link('CONTACT')}"
>
Contact
</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