Commit d9659531 by JonahStanley

Stylistic changes

CMS tests should now run on IE

CMS tests will now run on Safari

Rebased wrong

Forgot to update the test_acceptance.sh

Changed way of string splitting
parent b2480b5f
......@@ -12,6 +12,8 @@ Feature: Course checklists
# There are issues getting link to be active in browsers other than chrome
@skip_firefox
@skip_internetexplorer
@skip_safari
Scenario: A task can link to a location within Studio
Given I have opened Checklists
When I select a link to the course outline
......@@ -21,6 +23,8 @@ Feature: Course checklists
# There are issues getting link to be active in browsers other than chrome
@skip_firefox
@skip_internetexplorer
@skip_safari
Scenario: A task can link to a location outside Studio
Given I have opened Checklists
When I select a link to help page
......
......@@ -64,6 +64,10 @@ Feature: Course Overview
And I change an assignment's grading status
Then I am shown a notification
# Notification is not shown on reorder for IE
# Safari does not have moveMouseTo implemented
@skip_internetexplorer
@skip_safari
Scenario: Notification is shown on subsection reorder
Given I have opened a new course section in Studio
And I have added a new subsection
......
Feature: Course Settings
As a course author, I want to be able to configure my course settings.
# Safari has trouble keeps dates on refresh
@skip_safari
Scenario: User can set course dates
Given I have opened a new course in Studio
When I select Schedule and Details
......@@ -8,12 +10,16 @@ Feature: Course Settings
And I press the "Save" notification button
Then I see the set dates on refresh
# IE has trouble with saving information
@skip_internetexplorer
Scenario: User can clear previously set course dates (except start date)
Given I have set course dates
And I clear all the dates except start
And I press the "Save" notification button
Then I see cleared dates on refresh
# IE has trouble with saving information
@skip_internetexplorer
Scenario: User cannot clear the course start date
Given I have set course dates
And I press the "Save" notification button
......@@ -21,6 +27,10 @@ Feature: Course Settings
Then I receive a warning about course start date
And The previously set start date is shown on refresh
# IE has trouble with saving information
# Safari gets CSRF token errors
@skip_internetexplorer
@skip_safari
Scenario: User can correct the course start date warning
Given I have tried to clear the course start
And I have entered a new course start date
......@@ -28,12 +38,16 @@ Feature: Course Settings
Then The warning about course start date goes away
And My new course start date is shown on refresh
# Safari does not save + refresh properly through sauce labs
@skip_safari
Scenario: Settings are only persisted when saved
Given I have set course dates
And I press the "Save" notification button
When I change fields
Then I do not see the new changes persisted on refresh
# Safari does not save + refresh properly through sauce labs
@skip_safari
Scenario: Settings are reset on cancel
Given I have set course dates
And I press the "Save" notification button
......@@ -41,6 +55,8 @@ Feature: Course Settings
And I press the "Cancel" notification button
Then I do not see the changes
# Safari gets CSRF token errors
@skip_safari
Scenario: Confirmation is shown on save
Given I have opened a new course in Studio
When I select Schedule and Details
......
Feature: Course updates
As a course author, I want to be able to provide updates to my students
# Internet explorer can't select all so the update appears weirdly
@skip_internetexplorer
Scenario: Users can add updates
Given I have opened a new course in Studio
And I go to the course updates page
......@@ -8,6 +10,8 @@ Feature: Course updates
Then I should see the update "Hello"
And I see a "saving" notification
# Internet explorer can't select all so the update appears weirdly
@skip_internetexplorer
Scenario: Users can edit updates
Given I have opened a new course in Studio
And I go to the course updates page
......@@ -33,6 +37,8 @@ Feature: Course updates
Then I should see the date "June 1, 2013"
And I see a "saving" notification
# Internet explorer can't select all so the update appears weirdly
@skip_internetexplorer
Scenario: Users can change handouts
Given I have opened a new course in Studio
And I go to the course updates page
......
......@@ -6,6 +6,8 @@ Feature: Discussion Component Editor
And I edit and select Settings
Then I see three alphabetized settings and their expected values
# Safari doesn't save the name properly
@skip_safari
Scenario: User can modify display name
Given I have created a Discussion Tag
And I edit and select Settings
......
......@@ -13,7 +13,7 @@ Feature: Course Grading
When I add "6" new grades
Then I see I now have "5" grades
#Cannot reliably make the delete button appear so using javascript instead
# Cannot reliably make the delete button appear so using javascript instead
Scenario: Users can delete grading ranges
Given I have opened a new course in Studio
And I am viewing the grading settings
......@@ -21,6 +21,9 @@ Feature: Course Grading
And I delete a grade
Then I see I now have "2" grades
# IE and Safari cannot reliably drag and drop through selenium
@skip_internetexplorer
@skip_safari
Scenario: Users can move grading ranges
Given I have opened a new course in Studio
And I am viewing the grading settings
......@@ -85,6 +88,9 @@ Feature: Course Grading
When I change assignment type "Homework" to ""
Then the save button is disabled
# IE and Safari cannot type in grade range name
@skip_internetexplorer
@skip_safari
Scenario: User can edit grading range names
Given I have opened a new course in Studio
And I have populated the course
......
......@@ -6,6 +6,8 @@ Feature: HTML Editor
And I edit and select Settings
Then I see only the HTML display name setting
# Safari doesn't save the name properly
@skip_safari
Scenario: User can modify display name
Given I have created a Blank HTML Page
And I edit and select Settings
......
......@@ -7,12 +7,16 @@ Feature: Problem Editor
Then I see five alphabetized settings and their expected values
And Edit High Level Source is not visible
# Safari is having trouble saving the values on sauce
@skip_safari
Scenario: User can modify String values
Given I have created a Blank Common Problem
When I edit and select Settings
Then I can modify the display name
And my display name change is persisted on save
# Safari is having trouble saving the values on sauce
@skip_safari
Scenario: User can specify special characters in String values
Given I have created a Blank Common Problem
When I edit and select Settings
......@@ -25,6 +29,8 @@ Feature: Problem Editor
Then I can revert the display name to unset
And my display name is unset on save
# IE will not click the revert button properly
@skip_internetexplorer
Scenario: User can select values in a Select
Given I have created a Blank Common Problem
When I edit and select Settings
......@@ -32,6 +38,8 @@ Feature: Problem Editor
And my change to randomization is persisted
And I can revert to the default value for randomization
# Safari will input it as 35.
@skip_safari
Scenario: User can modify float input values
Given I have created a Blank Common Problem
When I edit and select Settings
......@@ -44,16 +52,22 @@ Feature: Problem Editor
When I edit and select Settings
Then if I set the weight to "abc", it remains unset
# Safari will input it as 234.
@skip_safari
Scenario: User cannot type decimal values integer number field
Given I have created a Blank Common Problem
When I edit and select Settings
Then if I set the max attempts to "2.34", it will persist as a valid integer
# Safari will input it incorrectly
@skip_safari
Scenario: User cannot type out of range values in an integer number field
Given I have created a Blank Common Problem
When I edit and select Settings
Then if I set the max attempts to "-3", it will persist as a valid integer
# Safari will input it as 35.
@skip_safari
Scenario: Settings changes are not saved on Cancel
Given I have created a Blank Common Problem
When I edit and select Settings
......@@ -67,6 +81,8 @@ Feature: Problem Editor
Then Edit High Level Source is visible
# This feature will work in Firefox only when Firefox is the active window
# IE will not interact with the high level source in sauce labs
@skip_internetexplorer
Scenario: High Level source is persisted for LaTeX problem (bug STUD-280)
Given I have created a LaTeX Problem
When I edit and compile the High Level Source
......
......@@ -15,6 +15,8 @@ Feature: Static Pages
And I "delete" the "Empty" page
Then I should not see a "Empty" static page
# Safari won't update the name properly
@skip_safari
Scenario: Users can edit static pages
Given I have opened a new course in Studio
And I go to the static pages page
......
......@@ -25,6 +25,8 @@ Feature: Create Subsection
And I reload the page
Then I see it marked as Homework
# Safari has trouble saving the date in Sauce
@skip_safari
Scenario: Set a due date in a different year (bug #256)
Given I have opened a new subsection in Studio
And I set the subsection release date to 12/25/2011 03:00
......
......@@ -5,6 +5,9 @@ Feature: Textbooks
When I go to the textbooks page
Then I should see a message telling me to create a new textbook
# IE and Safari on sauce labs will not upload the textbook correctly resulting in an error
@skip_internetexplorer
@skip_safari
Scenario: Create a textbook
Given I have opened a new course in Studio
And I go to the textbooks page
......
Feature: Upload Files
As a course author, I want to be able to upload files for my students
# Uploading isn't working on safari with sauce labs
@skip_safari
Scenario: Users can upload files
Given I have opened a new course in Studio
And I go to the files and uploads page
......@@ -8,6 +10,8 @@ Feature: Upload Files
Then I should see the file "test" was uploaded
And The url for the file "test" is valid
# Uploading isn't working on safari with sauce labs
@skip_safari
Scenario: Users can update files
Given I have opened a new course in studio
And I go to the files and uploads page
......@@ -15,6 +19,8 @@ Feature: Upload Files
And I upload the file "test"
Then I should see only one "test"
# Uploading isn't working on safari with sauce labs
@skip_safari
Scenario: Users can delete uploaded files
Given I have opened a new course in studio
And I go to the files and uploads page
......@@ -23,12 +29,16 @@ Feature: Upload Files
Then I should not see the file "test" was uploaded
And I see a confirmation that the file was deleted
# Uploading isn't working on safari with sauce labs
@skip_safari
Scenario: Users can download files
Given I have opened a new course in studio
And I go to the files and uploads page
When I upload the file "test"
Then I can download the correct "test" file
# Uploading isn't working on safari with sauce labs
@skip_safari
Scenario: Users can download updated files
Given I have opened a new course in studio
And I go to the files and uploads page
......
......@@ -6,6 +6,8 @@ Feature: Video Component Editor
And I edit the component
Then I see the correct video settings and default values
# Safari has trouble saving values on Sauce
@skip_safari
Scenario: User can modify Video display name
Given I have created a Video component
And I edit the component
......
......@@ -10,15 +10,21 @@ Feature: Video Component
Given I have clicked the new unit button
Then creating a video takes a single click
# Sauce Labs cannot delete cookies
@skip_sauce
Scenario: Captions are hidden correctly
Given I have created a Video component
And I have hidden captions
Then when I view the video it does not show the captions
# Sauce Labs cannot delete cookies
@skip_sauce
Scenario: Captions are shown correctly
Given I have created a Video component
Then when I view the video it does show the captions
# Sauce Labs cannot delete cookies
@skip_sauce
Scenario: Captions are toggled correctly
Given I have created a Video component
And I have toggled captions
......
......@@ -119,7 +119,7 @@ def initial_setup(server):
# If we were unable to get a valid session within the limit of attempts,
# then we cannot run the tests.
if not success:
raise IOError("Could not acquire valid {driver} browser session.".format(driver='remote'))
raise IOError("Could not acquire valid {driver} browser session.".format(driver=browser_driver))
world.browser.driver.set_window_size(1280, 1024)
......
......@@ -32,11 +32,15 @@ TESTS_FAILED=0
export DISPLAY=:1
SKIP_TESTS=""
# Testing for the existance of these environment variables
if [ ! -z ${LETTUCE_BROWSER+x} ]; then
SKIP_TESTS="--tag -skip_$LETTUCE_BROWSER"
fi
if [ ! -z ${SAUCE_ENABLED+x} ]; then
SKIP_TESTS="--tag -skip_sauce --tag -skip_$SAUCE_BROWSER"
# SAUCE_INFO is a - seperated string PLATFORM-BROWSER-VERSION-DEVICE
# Error checking is done in the setting up of the browser
IFS='-' read -a SAUCE <<< "${SAUCE_INFO}"
SKIP_TESTS="--tag -skip_sauce --tag -skip_${SAUCE[1]}"
fi
# Run the lms and cms acceptance tests
......
......@@ -88,6 +88,9 @@ MITX_FEATURES['AUTOMATIC_AUTH_FOR_TESTING'] = True
# We do not yet understand why this occurs. Setting this to true is a stopgap measure
USE_I18N = True
MITX_FEATURES['ENABLE_FEEDBACK_SUBMISSION'] = True
FEEDBACK_SUBMISSION_EMAIL = 'dummy@example.com'
# Include the lettuce app for acceptance testing, including the 'harvest' django-admin command
INSTALLED_APPS += ('lettuce.django',)
LETTUCE_APPS = ('courseware',)
......
......@@ -27,6 +27,8 @@ DESIRED_CAPABILITIES = {
'android': DesiredCapabilities.ANDROID
}
# All keys must be URL and JSON encodable
# PLATFORM-BROWSER-VERSION_NUM-DEVICE
ALL_CONFIG = {
'Linux-chrome--': ['Linux', 'chrome', '', ''],
'Windows 8-chrome--': ['Windows 8', 'chrome', '', ''],
......@@ -45,15 +47,7 @@ ALL_CONFIG = {
'Windows 8-internetexplorer-10-': ['Windows 8', 'internetexplorer', '10', ''],
}
#HACK
#This needs to be done because Jenkins needs to satisfy URLs, JSON, BASH, SAUCE, and PYTHON
#This is the simplest way to adhere to all of these requirements and still be readable
# PLATFORM-BROWSER-VERSION_NUM-DEVICE
DEFAULT_CONFIG = 'Linux-chrome--'
SAUCE_CONFIG = os.environ.get('SAUCE_INFO', DEFAULT_CONFIG)
SAUCE_INFO = ALL_CONFIG[SAUCE_CONFIG]
SAUCE_INFO = ALL_CONFIG.get(os.environ.get('SAUCE_INFO', 'Linux-chrome--'))
# Information needed to utilize Sauce Labs.
SAUCE = {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment