Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
137 commits
Select commit Hold shift + click to select a range
83d12cd
add scroll to top on vertical view change
Aug 6, 2013
8432269
add jasmine test for scroll to top
Aug 8, 2013
cdf0eef
Consider redirect code as succcesful
Sep 16, 2013
e726ef4
Link to How To Contribute wiki page
jtauber Sep 16, 2013
ca1f4ba
Moved to a more comprehensive contributing doc.
jtauber Sep 16, 2013
9b65a1a
Link to wiki with absolute URLs
jtauber Sep 16, 2013
a1693dc
Added linebreaks.
jtauber Sep 16, 2013
0f81bdc
Properly handle error responses
Sep 16, 2013
4fdf7a4
Prompt before leaving page
Sep 17, 2013
d8e9ffb
Added missing test in StaticImageBookTest
Sep 19, 2013
0d0cb56
Speed up Location creation returning existing locations where possible
cpennington Sep 19, 2013
2c90dc7
Don't access kvs directly but use x_module and field_data mechanisms
Sep 16, 2013
b9a7c7f
Create new structure allows override of usage id and category
Sep 16, 2013
bf633f9
Perform auth checks in middleware
Sep 20, 2013
7a8d463
Put static server middleware after the middleware it requires
Sep 20, 2013
268b5b4
Remove cache workaround
Sep 20, 2013
3c3edac
Fixed tests name in staticbook
Sep 23, 2013
c196d18
i18n fix
Sep 23, 2013
b4e6a8b
Fix order-dependency in tests
Sep 23, 2013
40d11c7
location mapper maturation
Sep 16, 2013
bd56ee2
split get_item uses loc_mapper to decode old style Locations
Sep 16, 2013
379a147
Begin transactional with_version impl
Sep 16, 2013
ad2da44
Make Textbooks properly lazy
cpennington Sep 19, 2013
cfa2b27
Turn Locations into dicts less often
cpennington Sep 19, 2013
25ea91e
Merge pull request #1061 from cpennington/faster-location-urls
cpennington Sep 23, 2013
63b841b
Merge pull request #1062 from cpennington/speed-up-location-creation
cpennington Sep 23, 2013
e5c90d3
Fix middleware order in CMS.
Sep 23, 2013
a4ee129
Merge pull request #1095 from edx/dhm/asset_bug
dmitchell Sep 23, 2013
199f898
Merge pull request #1087 from edx/jkarni/fix/revert-xml-comments
Sep 23, 2013
97cd5a8
Merge pull request #1013 from edx/jkarni/fix/import-warnings
Sep 23, 2013
5347a49
Disable test that fails intermittently in master
Sep 23, 2013
f8cd482
Replace date lib w/ simpler tzAbbr
Sep 23, 2013
427386c
Merge pull request #1102 from edx/will/disable-more-js-tests
Sep 23, 2013
9836fd5
Speed control now regains focus after a speed entry has been selected…
Sep 20, 2013
ffa49b0
Added tests
Sep 23, 2013
2cc9679
Used Jasmine jQuery for tests instead
Sep 24, 2013
feb95eb
Fixed tests
Sep 24, 2013
3a5d7d8
Addressed PR comments
Sep 24, 2013
3ca74c0
Merge pull request #1084 from edx/jmclaus/bugfix_focus_speed_control
Sep 24, 2013
3b61d57
Ensure location is valid before trying to fetch
Sep 24, 2013
761590b
Merge pull request #1053 from edx/usman/static-book-url
symbolist Sep 24, 2013
f303649
Speed up lti acceptance test for remote webdriver.
Sep 20, 2013
20ea287
Speed up problems feature tests
Sep 19, 2013
002f3ef
Speed up waiting for elements not present on remote webdriver sessions.
Sep 19, 2013
818f4f2
Update event doc from wiki
stroilova Aug 27, 2013
f898f72
Added tags to acceptance tests to define multiple shards.
Sep 24, 2013
6ebb753
Write xunit reports for acceptance tests
Sep 19, 2013
c399512
Merge pull request #1075 from edx/zoldak/xunit-acceptance-reports
Sep 24, 2013
6d41669
Merge pull request #809 from edx/event_spec_update
stroilova Sep 24, 2013
73e0388
Merge pull request #1083 from edx/zoldak/speedy-lms-acceptance
Sep 24, 2013
7669b4d
Namespace the acceptance tests so they show up nicely in jenkins
Sep 24, 2013
1a0b752
Review fixes
Sep 24, 2013
ad939b1
Merge pull request #1090 from edx/jkarni/feature/middleware-locked-as…
Sep 24, 2013
7275f85
Merge branch 'release'
Sep 24, 2013
1b59039
Add "Download CSV of all student anonymized IDs" button to instructor…
nparlante Sep 23, 2013
d1a82f2
Import/export static content properties
Sep 20, 2013
8e7fc15
Test asset import/export roundtrip w/ lock setting.
Sep 23, 2013
20e4d58
Add documentation and comments.
Sep 24, 2013
4ee9ef6
Clean up some old pep8/pylint violations
dianakhuang Sep 24, 2013
fd06640
Merge pull request #1091 from edx/assets/persist_lock
dmitchell Sep 24, 2013
f1ccf1c
Integrate split testing and LMS tabs experiments
rlucioni Sep 9, 2013
e7e03f1
Refactor tab tests
rlucioni Sep 18, 2013
8b44892
Fix for bug BLD-359: Unnecessary focus outline around Video Player.
Sep 25, 2013
dd788c8
Merge pull request #1107 from edx/dhm/bug_attrs
dmitchell Sep 25, 2013
19ee540
Merge pull request #1115 from edx/diana/verify-pep8-pylint
dianakhuang Sep 25, 2013
cd696e7
PdfViewer: Added missing link to compatibility.js
Sep 25, 2013
cae6e82
Knock 10 more seconds off the acceptance tests.
Sep 25, 2013
a8349a0
Merge pull request #1120 from edx/valera/fix_for_unnecessary_outline_…
valera-rozuvan Sep 25, 2013
6b7cb42
Merge pull request #1123 from edx/zoldak/speedy-cms-acceptance
Sep 25, 2013
7bd5454
Merge pull request #597 from edx/feature/msteele/scrollup
Sep 25, 2013
2b54922
Fix intermittent failure in OpenID test
Sep 25, 2013
f4b37b2
Merge pull request #1060 from cpennington/lazy-textbooks
cpennington Sep 25, 2013
2338ed2
Merge pull request #1126 from edx/will/fix-openid-test
Sep 25, 2013
47621b5
Merge pull request #1112 from edx/will/shard-acceptance-tests
Sep 25, 2013
ef26e8b
Just write the loc name as the key in the policy file
Sep 25, 2013
f932881
Test importing exported course over a new course
Sep 25, 2013
982d22d
edx.org/LMS: revises graphic-based login and registration banner text…
talbs Sep 25, 2013
37d906e
Add the ability to set expiration dates on course modes.
dianakhuang Sep 24, 2013
82af8d4
Merge pull request #1124 from edx/dhm/asset_policy
dmitchell Sep 25, 2013
ac0e65a
Update CHANGELOG
rlucioni Sep 25, 2013
c124a33
Merge pull request #829 from edx/renzo/ab-testing
rlucioni Sep 25, 2013
d225b85
Port get-anonymized-id feature to new instructor dashboard
nparlante Sep 24, 2013
78829a3
Merge pull request #1127 from edx/diana/modes-expiration-dates
dianakhuang Sep 25, 2013
c64e04d
Add the ability to lock assets.
Sep 19, 2013
370872f
ui changes from design team feedback on studio assets page
Sep 24, 2013
f10cf29
Update upload test for what actually works now.
Sep 24, 2013
7700ec6
addressing PR sass/html comments on studio assets
Sep 25, 2013
6dce7f2
Asset locking feature.
Sep 25, 2013
5e475c8
Code review feedback.
Sep 25, 2013
1d7f891
Delete asset from cache.
Sep 25, 2013
79c2cdc
switching studio assets lock to use checkbox instead of link
Sep 25, 2013
2cbdaae
Updates based on switching to checkbox for locking.
Sep 25, 2013
08cb469
Merge pull request #1104 from edx/nick/anon-userids
nparlante Sep 26, 2013
111a6ae
turning off sass debug mode in assets.rake
Sep 5, 2013
9f93c3c
Merge pull request #1012 from edx/fix/frances/sass-debug-off
talbs Sep 26, 2013
190b418
Merge pull request #1121 from edx/dhm/timezone_display
dmitchell Sep 26, 2013
42f286b
Merge pull request #1069 from edx/christina/lock-assets
Sep 26, 2013
68ce6ed
Second batch of ORA UI fixes:
caesar2164 Sep 18, 2013
bbd902f
Last Changes before Merge
caesar2164 Sep 26, 2013
b4fa316
Migrate data from old mongo to split mongo
Sep 16, 2013
934b3ca
Check has_children before accessing children
Sep 16, 2013
c1789ad
Always return a Locator: cases weren't exhaustive.
Sep 17, 2013
d328c53
Cached course entry: separate structure from identity
Sep 17, 2013
59b3147
Separate db config from modulestore config parms
Sep 18, 2013
f63aa0f
Pylint and pep8 hygiene
Sep 18, 2013
7d4ccf6
Merge pull request #1066 from edx/giulio/ORA-fixes-2
caesar2164 Sep 26, 2013
2379e7c
Merge pull request #1029 from edx/dhm/migrate_mongo
dmitchell Sep 26, 2013
8e6c0ea
Wrap logic for selecting options in acceptance tests
Sep 26, 2013
3c88ccb
Use comments to skip tests instead of a tag
Sep 26, 2013
0858dfd
Merge pull request #1141 from edx/zoldak/fix-problem-test
Sep 26, 2013
b86ab28
Merge pull request #1129 from edx/talbs/fix-lms-banners
talbs Sep 26, 2013
7aea736
Merge branch 'release'
Sep 26, 2013
667a1ea
Stanford paid course registration
jbau Sep 24, 2013
1737984
Merge pull request #1122 from edx/usman/lms1167-pdfjs-update
symbolist Sep 27, 2013
ef6d58a
Merge pull request #1005 from edx/jtauber/link-to-how-to-contribute
jtauber Sep 27, 2013
9385b57
Merge pull request #1143 from edx/will/skip-tests-with-comments
Sep 27, 2013
c1d555b
Merge pull request #1118 from edx/jbau/shoppingcart-stanford
jbau Sep 27, 2013
bf5a801
Make discussion elements change color on focus
Sep 27, 2013
8a2bd25
Visual rearrangement of new dash "Student Admin" page
Sep 24, 2013
07e76b3
Enable use of student usernames on student admin page
Sep 26, 2013
086f544
Fix, and add more, tests
Sep 26, 2013
91d85f5
Enable alerts when a task succeeds.
Sep 26, 2013
3813e51
Add more feedback for instructors on Student Admin section of the dash.
Sep 27, 2013
6b5d12e
Merge pull request #1159 from edx/gprice/forum-focus-color
Sep 27, 2013
44b4204
Merge pull request #1155 from edx/sarina/ins-dash-student-admin-2
Sep 27, 2013
f4971e7
Add accessible labels for forum post body inputs
Sep 27, 2013
3e3ad43
Merge pull request #1161 from edx/gprice/forums-labels
Sep 27, 2013
f39886e
Ensure nav sidebar is sized correctly on page load
Sep 27, 2013
4ab47c4
Fix mako syntax in rubric template.
Sep 27, 2013
b12e502
Merge pull request #1168 from edx/fix/vik/num-results-template
Sep 27, 2013
202e4f9
make seq tooltips appear on focus
adampalay Sep 27, 2013
d816d5f
update coffeescript to dynamically render sr spans
kevinchugh Sep 27, 2013
031f331
Merge pull request #1157 from edx/adam/a11y
adampalay Sep 27, 2013
cbbb5c7
Improve focus management of forums nav sidebar
Sep 27, 2013
9a5e6f1
code review cleanup
kevinchugh Sep 27, 2013
db325e7
Merge pull request #1169 from edx/gprice/forum-load-more-focus
Sep 27, 2013
c850be4
Merge pull request #1167 from edx/fix/kevin/forums_accessibility
Sep 27, 2013
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ These are notable changes in edx-platform. This is a rolling list of changes,
in roughly chronological order, most recent first. Add your entries at or near
the top. Include a label indicating the component affected.

LMS: Add split testing functionality for internal use.

Studio and LMS: add ability to lock assets (cannot be viewed unless registered for class).

LMS: Improved accessibility of parts of forum navigation sidebar.

LMS: enhanced accessibility labeling and aria support for the discussion forum new post dropdown as well as response and comment area labeling.
Expand Down
22 changes: 22 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
Contributions are very welcome. The easiest way is to fork the repo and then
make a pull request from your fork. Before your pull request is merged, it will
be reviewed by at least one person. There may be feedback so expect comments on
the pull request. Add yourself to the AUTHORS file in your first pull request.

Please review:

* [Python Guidelines](https://github.com/edx/edx-platform/wiki/Python-Guidelines)
* [Javascript Guidelines](https://github.com/edx/edx-platform/wiki/Javascript-Guidelines)
* [Testing](https://github.com/edx/edx-platform/blob/master/docs/internal/testing.md)

Coding conventions should be followed and your commit should *increase* test
coverage, not decrease it. For more involved contributions, you may want to
discuss your intentions on the mailing list *before* you start coding.

Before your first pull request is merged, you'll need to sign the
[individual contributor agreement](http://code.edx.org/individual-contributor-agreement.pdf)
and send it in. This confirms you have the authority to contribute the code in
the pull request and ensures we can relicense it.

If you have any questions, please ask on the
[mailing list](https://groups.google.com/forum/#!forum/edx-code).
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -345,9 +345,9 @@ with `overview.md` to get an introduction to the architecture of the system.
How to Contribute
-----------------

Contributions are very welcome. The easiest way is to fork this repo, and then
make a pull request from your fork. The first time you make a pull request, you
may be asked to sign a Contributor Agreement.
Contributions are very welcome.

Please read [How To Contribute](https://github.com/edx/edx-platform/wiki/How-To-Contribute) for details.

Reporting Security Issues
-------------------------
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Feature: Advanced (manual) course policy
@shard_1
Feature: CMS.Advanced (manual) course policy
In order to specify course policy settings for which no custom user interface exists
I want to be able to manually enter JSON key /value pairs

Expand Down
3 changes: 2 additions & 1 deletion cms/djangoapps/contentstore/features/checklists.feature
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Feature: Course checklists
@shard_1
Feature: CMS.Course checklists

Scenario: A course author sees checklists defined by edX
Given I have opened a new course in Studio
Expand Down
45 changes: 45 additions & 0 deletions cms/djangoapps/contentstore/features/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -300,3 +300,48 @@ def upload_file(filename):
world.browser.attach_file('file', os.path.abspath(path))
button_css = '.upload-dialog .action-upload'
world.css_click(button_css)


@step(u'"([^"]*)" logs in$')
def other_user_login(step, name):
step.given('I log out')
world.visit('/')

signin_css = 'a.action-signin'
world.is_css_present(signin_css)
world.css_click(signin_css)

def fill_login_form():
login_form = world.browser.find_by_css('form#login_form')
login_form.find_by_name('email').fill(name + '@edx.org')
login_form.find_by_name('password').fill("test")
login_form.find_by_name('submit').click()
world.retry_on_exception(fill_login_form)
assert_true(world.is_css_present('.new-course-button'))
world.scenario_dict['USER'] = get_user_by_email(name + '@edx.org')


@step(u'the user "([^"]*)" exists( as a course (admin|staff member|is_staff))?$')
def create_other_user(_step, name, has_extra_perms, role_name):
email = name + '@edx.org'
user = create_studio_user(uname=name, password="test", email=email)
if has_extra_perms:
if role_name == "is_staff":
user.is_staff = True
else:
if role_name == "admin":
# admins get staff privileges, as well
roles = ("staff", "instructor")
else:
roles = ("staff",)
location = world.scenario_dict["COURSE"].location
for role in roles:
groupname = get_course_groupname_for_role(location, role)
group, __ = Group.objects.get_or_create(name=groupname)
user.groups.add(group)
user.save()


@step('I log out')
def log_out(_step):
world.visit('logout')
131 changes: 65 additions & 66 deletions cms/djangoapps/contentstore/features/component.feature
Original file line number Diff line number Diff line change
@@ -1,72 +1,71 @@
Feature: Component Adding
@shard_1
Feature: CMS.Component Adding
As a course author, I want to be able to add a wide variety of components

@skip
Scenario: I can add components
Given I have opened a new course in studio
And I am editing a new unit
When I add the following components:
| Component |
| Discussion |
| Blank HTML |
| LaTex |
| Blank Problem|
| Dropdown |
| Multi Choice |
| Numerical |
| Text Input |
| Advanced |
| Circuit |
| Custom Python|
| Image Mapped |
| Math Input |
| Problem LaTex|
| Adaptive Hint|
| Video |
Then I see the following components:
| Component |
| Discussion |
| Blank HTML |
| LaTex |
| Blank Problem|
| Dropdown |
| Multi Choice |
| Numerical |
| Text Input |
| Advanced |
| Circuit |
| Custom Python|
| Image Mapped |
| Math Input |
| Problem LaTex|
| Adaptive Hint|
| Video |
#Scenario: I can add components
# Given I have opened a new course in studio
# And I am editing a new unit
# When I add the following components:
# | Component |
# | Discussion |
# | Blank HTML |
# | LaTex |
# | Blank Problem|
# | Dropdown |
# | Multi Choice |
# | Numerical |
# | Text Input |
# | Advanced |
# | Circuit |
# | Custom Python|
# | Image Mapped |
# | Math Input |
# | Problem LaTex|
# | Adaptive Hint|
# | Video |
# Then I see the following components:
# | Component |
# | Discussion |
# | Blank HTML |
# | LaTex |
# | Blank Problem|
# | Dropdown |
# | Multi Choice |
# | Numerical |
# | Text Input |
# | Advanced |
# | Circuit |
# | Custom Python|
# | Image Mapped |
# | Math Input |
# | Problem LaTex|
# | Adaptive Hint|
# | Video |

@skip
Scenario: I can delete Components
Given I have opened a new course in studio
And I am editing a new unit
And I add the following components:
| Component |
| Discussion |
| Blank HTML |
| LaTex |
| Blank Problem|
| Dropdown |
| Multi Choice |
| Numerical |
| Text Input |
| Advanced |
| Circuit |
| Custom Python|
| Image Mapped |
| Math Input |
| Problem LaTex|
| Adaptive Hint|
| Video |
When I will confirm all alerts
And I delete all components
Then I see no components
#Scenario: I can delete Components
# Given I have opened a new course in studio
# And I am editing a new unit
# And I add the following components:
# | Component |
# | Discussion |
# | Blank HTML |
# | LaTex |
# | Blank Problem|
# | Dropdown |
# | Multi Choice |
# | Numerical |
# | Text Input |
# | Advanced |
# | Circuit |
# | Custom Python|
# | Image Mapped |
# | Math Input |
# | Problem LaTex|
# | Adaptive Hint|
# | Video |
# When I will confirm all alerts
# And I delete all components
# Then I see no components

Scenario: I see a prompt on delete
Given I have opened a new course in studio
Expand Down
5 changes: 3 additions & 2 deletions cms/djangoapps/contentstore/features/course-overview.feature
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Feature: Course Overview
@shard_1
Feature: CMS.Course Overview
In order to quickly view the details of a course's section and set release dates and grading
As a course author
I want to use the course overview page
Expand Down Expand Up @@ -68,7 +69,7 @@ Feature: Course Overview
# Safari does not have moveMouseTo implemented
@skip_internetexplorer
@skip_safari
Scenario: Notification is shown on subsection reorder
Scenario: Notification is shown on subsection reorder
Given I have opened a new course section in Studio
And I have added a new subsection
And I have added a new subsection
Expand Down
3 changes: 2 additions & 1 deletion cms/djangoapps/contentstore/features/course-settings.feature
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Feature: Course Settings
@shard_2
Feature: CMS.Course Settings
As a course author, I want to be able to configure my course settings.

# Safari has trouble keeps dates on refresh
Expand Down
3 changes: 2 additions & 1 deletion cms/djangoapps/contentstore/features/course-team.feature
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Feature: Course Team
@shard_2
Feature: CMS.Course Team
As a course author, I want to be able to add others to my team

Scenario: Admins can add other users
Expand Down
54 changes: 6 additions & 48 deletions cms/djangoapps/contentstore/features/course-team.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,9 @@
#pylint: disable=W0621

from lettuce import world, step
from common import create_studio_user
from django.contrib.auth.models import Group
from auth.authz import get_course_groupname_for_role, get_user_by_email
from nose.tools import assert_true, assert_in # pylint: disable=E0611

PASSWORD = 'test'
EMAIL_EXTENSION = '@edx.org'


@step(u'(I am viewing|s?he views) the course team settings')
def view_grading_settings(_step, whom):
Expand All @@ -18,32 +13,14 @@ def view_grading_settings(_step, whom):
world.css_click(link_css)


@step(u'the user "([^"]*)" exists( as a course (admin|staff member))?$')
def create_other_user(_step, name, has_extra_perms, role_name):
email = name + EMAIL_EXTENSION
user = create_studio_user(uname=name, password=PASSWORD, email=email)
if has_extra_perms:
location = world.scenario_dict["COURSE"].location
if role_name == "admin":
# admins get staff privileges, as well
roles = ("staff", "instructor")
else:
roles = ("staff",)
for role in roles:
groupname = get_course_groupname_for_role(location, role)
group, __ = Group.objects.get_or_create(name=groupname)
user.groups.add(group)
user.save()


@step(u'I add "([^"]*)" to the course team')
def add_other_user(_step, name):
new_user_css = 'a.create-user-button'
world.css_click(new_user_css)
world.wait(0.5)

email_css = 'input#user-email-input'
world.css_fill(email_css, name + EMAIL_EXTENSION)
world.css_fill(email_css, name + '@edx.org')
if world.is_firefox():
world.trigger_event(email_css)
confirm_css = 'form.create-user button.action-primary'
Expand All @@ -53,7 +30,7 @@ def add_other_user(_step, name):
@step(u'I delete "([^"]*)" from the course team')
def delete_other_user(_step, name):
to_delete_css = '.user-item .item-actions a.remove-user[data-id="{email}"]'.format(
email="{0}{1}".format(name, EMAIL_EXTENSION))
email="{0}{1}".format(name, '@edx.org'))
world.css_click(to_delete_css)
# confirm prompt
# need to wait for the animation to be done, there isn't a good success condition that won't work both on latest chrome and jenkins
Expand All @@ -74,7 +51,7 @@ def other_delete_self(_step):
@step(u'I make "([^"]*)" a course team admin')
def make_course_team_admin(_step, name):
admin_btn_css = '.user-item[data-email="{email}"] .user-actions .add-admin-role'.format(
email=name+EMAIL_EXTENSION)
email=name+'@edx.org')
world.css_click(admin_btn_css)


Expand All @@ -83,31 +60,12 @@ def remove_course_team_admin(_step, outer_capture, name):
if outer_capture == "myself":
email = world.scenario_dict["USER"].email
else:
email = name + EMAIL_EXTENSION
email = name + '@edx.org'
admin_btn_css = '.user-item[data-email="{email}"] .user-actions .remove-admin-role'.format(
email=email)
world.css_click(admin_btn_css)


@step(u'"([^"]*)" logs in$')
def other_user_login(_step, name):
world.visit('logout')
world.visit('/')

signin_css = 'a.action-signin'
world.is_css_present(signin_css)
world.css_click(signin_css)

def fill_login_form():
login_form = world.browser.find_by_css('form#login_form')
login_form.find_by_name('email').fill(name + EMAIL_EXTENSION)
login_form.find_by_name('password').fill(PASSWORD)
login_form.find_by_name('submit').click()
world.retry_on_exception(fill_login_form)
assert_true(world.is_css_present('.new-course-button'))
world.scenario_dict['USER'] = get_user_by_email(name + EMAIL_EXTENSION)


@step(u'I( do not)? see the course on my page')
@step(u's?he does( not)? see the course on (his|her) page')
def see_course(_step, do_not_see, gender='self'):
Expand All @@ -123,7 +81,7 @@ def see_course(_step, do_not_see, gender='self'):
@step(u'"([^"]*)" should( not)? be marked as an admin')
def marked_as_admin(_step, name, not_marked_admin):
flag_css = '.user-item[data-email="{email}"] .flag-role.flag-role-admin'.format(
email=name+EMAIL_EXTENSION)
email=name+'@edx.org')
if not_marked_admin:
assert world.is_css_not_present(flag_css)
else:
Expand Down Expand Up @@ -161,7 +119,7 @@ def can_make_course_admin(_step, can_not_make_admin, outer_capture, name):
if outer_capture == "myself":
email = world.scenario_dict["USER"].email
else:
email = name + EMAIL_EXTENSION
email = name + '@edx.org'
add_button_css = '.user-item[data-email="{email}"] .add-admin-role'.format(email=email)
if can_not_make_admin:
assert world.is_css_not_present(add_button_css)
Expand Down
Loading