Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
139 changes: 91 additions & 48 deletions integration_testing/features/manage-resources/create-exercise.feature
Original file line number Diff line number Diff line change
Expand Up @@ -4,78 +4,121 @@ Feature: Create an exercise
Given I am signed in to Studio
And I am at the channel editor page

Scenario: Create an exercise with questions of type *Single choice*
Scenario: Create a new exercise (Completion: When goal is met - Goal: 100% correct)
When I click the *Add* button
And I select the *New exercise* option
Then I see the *Details* tab of the *New exercise* modal
When I fill in the required fields (*Title*, *Completion* and *Goal*)
When I fill in all of the required fields
And I set the completion criteria to *When goal is met - Goal: 100% correct)* #repeat with the rest of the available goal types
And I click the *Questions* tab
Then I see the *New question* button
Then I see the text: *Exercise has no questions*
And I see a *New question* button
When I click the *New question* button
Then I see the question editor
And I see that *Single choice* is the default *Response type*
When I fill in the question text in the question editor field
And I add an image
And I provide answers
And I select one answer as the correct answer
And I provide a hint
Then I've completed the creation of the question of type *Single choice* #repeat the same steps to add as many questions as necessary
When I click the *Finish* button
Then I am returned to the main topic tree view
And I can see the newly created exercise
When I add one or several questions of the desired type
And I add answers and hints as necessary
And I click the *Finish* button
Then I am back at the channel editor page
And I can see the newly added exercise
And I see a small green dot indicating that the exercise is unpublished

Scenario: Create an exercise with questions of type *Multiple choice*
Scenario: Create a new exercise - practice quiz
When I click the *Add* button
And I select the *New exercise* option
Then I see the *Details* tab of the *New exercise* modal
When I fill in the required fields (*Title*, *Completion* and *Goal*)
When I fill in all of the required fields
And I set the completion criteria to *Practice quiz*
And I click the *Questions* tab
Then I see the *New question* button
Then I see the text: *Exercise has no questions*
And I see a *New question* button
When I click the *New question* button
Then I see the question editor
When I select the *Multiple choice* option from the *Response type* drop-down
And I fill in the question text in the question editor field
And I add an image
And I provide answers
And I select at least one answer as the correct answer
And I provide a hint
Then I've completed the creation of the question of type *Multiple choice* #repeat the same steps to add as many questions as necessary
When I click the *Finish* button
Then I am returned to the main topic tree view
And I can see the newly created exercise
When I add one or several questions of the desired type
And I add answers and hints as necessary
And I click the *Finish* button
Then I am back at the channel editor page
And I can see the newly added exercise
And I see a small green dot indicating that the exercise is unpublished

Scenario: Create an exercise with questions of type *Numeric input*
Scenario: Create a new exercise - survey
When I click the *Add* button
And I select the *New exercise* option
Then I see the *Details* tab of the *New exercise* modal
When I fill in the required fields (*Title*, *Completion* and *Goal*)
When I fill in all of the required fields
And I set the completion criteria to *Survey*
And I click the *Questions* tab
Then I see the *New question* button
Then I see the text: *Exercise has no questions*
And I see a *New question* button
When I click the *New question* button
Then I see the question editor
When I add one or several questions of the desired type
And I add answers and hints as necessary
And I click the *Finish* button
Then I am back at the channel editor page
And I can see the newly added exercise
And I see a small green dot indicating that the exercise is unpublished

Scenario: Existing and newly created exercises behave consistently
When I open a published channel containing previously created exercises with various completion types and questions
Then I can see all exercises displayed in the channel editor page
And exercises which were previously marked as *Incomplete* are still marked as *Incomplete*
And exercises without an *Incomplete* indicator are still displayed without it
And existing and newly created exercises look and function the same

Scenario: Create an exercise with questions of type *Single choice*
Given I am at the *Questions* tab
When I click the *New question* button
Then I see the question editor
And I see that *Single choice* is the default *Response type*
When I fill in the question text in the question editor field using all of the available editor options such as adding and resizing an image, editing the text or inserting formulas
And I provide answers
And I select one answer as the correct answer
And I provide a hint
And I click the *Finish* button
Then I am back at the channel editor page
And I can see the newly added exercise
And I see a small green dot indicating that the exercise is unpublished

Scenario: Create an exercise with questions of type *Multiple choice*
Given I am at the question editor
When I select the *Multiple choice* option from the *Response type* drop-down
And I fill in the question text in the question editor field using all of the available editor options such as adding and resizing an image, editing the text or inserting formulas
And I provide answers
And I select one answer as the correct answer
And I provide a hint
And I click the *Finish* button
Then I am back at the channel editor page
And I can see the newly added exercise
And I see a small green dot indicating that the exercise is unpublished

Scenario: Create an exercise with questions of type *Numeric input*
Given I am at the question editor
When I select the *Numeric input* option from the *Response type* drop-down
And I fill in the question text in the question editor field
And I fill in the question text in the question editor field using all of the available editor options such as adding and resizing an image, editing the text or inserting formulas
And I provide answers
And I select one answer as the correct answer
And I provide a hint
Then I've completed the creation of the question of type *Numeric input* #repeat the same steps to add as many questions as necessary
When I click the *Finish* button
Then I am returned to the main topic tree view
And I can see the newly created exercise
And I click the *Finish* button
Then I am back at the channel editor page
And I can see the newly added exercise
And I see a small green dot indicating that the exercise is unpublished

Scenario: Create an exercise with questions of type *True/False*
When I click the *Add* button
And I select the *New exercise* option
Then I see the *Details* tab of the *New exercise* modal
When I fill in the required fields (*Title*, *Completion* and *Goal*)
And I click the *Questions* tab
Then I see the *New question* button
When I click the *New question* button
Then I see the question editor
Given I am at the question editor
When I select the *True/False* option from the *Response type* drop-down
And I fill in the question text in the question editor field
And I select either *True* or *False* as the correct answer
And I fill in the question text in the question editor field using all of the available editor options such as adding and resizing an image, editing the text or inserting formulas
And I select one answer as the correct answer
And I provide a hint
Then I've completed the creation of the question of type *True/False* #repeat the same steps to add as many questions as necessary
When I click the *Finish* button
Then I am returned to the main topic tree view
And I can see the newly created exercise
And I click the *Finish* button
Then I am back at the channel editor page
And I can see the newly added exercise
And I see a small green dot indicating that the exercise is unpublished

Scenario: Create an exercise with questions of type *Free response*
Given I am at the question editor for an exercise of type Survey
When I select the *Free response* option from the *Response type* drop-down
And I fill in the question text in the question editor field using all of the available editor options such as adding and resizing an image, editing the text or inserting formulas
And I click the *Finish* button
Then I am back at the channel editor page
And I can see the newly added exercise
And I see a small green dot indicating that the exercise is unpublished
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Feature: Restore resources from trash

Background:
Given I am signed in to Studio
And I am at the channel editing page
And I am at the channel editor page
And I have already removed some resources
And I have opened the trash page

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Feature: Sync resources
Studio users need to be able to sync and update the resources in their channels that have been imported from other channels, but have been modified since the original import.
Studio users need to be able to sync and update the resources in their channels which have been imported from other channels, but have been modified since the original import.

Background:
Given I am signed in to Studio
Expand All @@ -10,12 +10,14 @@ Feature: Sync resources
Given there is a new version of the resource file in <channel_b>
When I click the *···* button in the top-right corner
And I select the *Sync resources* option
Then I see *Sync resources* modal window
And I see options to sync files, resource details, titles and description, assessment details
Then I see the *Sync resources* modal window
And I see the *Select what you would like to sync* section with options to sync files, resource details, titles and description, assessment details
When I select the Files checkbox
And I click the *Continue* button
Then I see the *Confirm sync* modal
When I click *Sync*
And I see the following info: You are about to sync and update the following: Files
And I see a warning that this will overwrite any changes I've made to copied or imported resources
When I click the *Sync* button
Then the modal closes
When after a period of time I refresh the page
And inspect the updated resource(s)
Expand All @@ -24,7 +26,7 @@ Feature: Sync resources
Scenario: Sync resource details
Given there is a new version of the resource file in <channel_b>
And I am at the *Sync resources* modal window
When I select the *Tags* checkbox
When I select the *Resource details* checkbox
And click the *Continue* button
Then I see the *Confirm sync* modal
When I click *Sync*
Expand Down Expand Up @@ -60,11 +62,11 @@ Feature: Sync resources
Scenario: Edited resource metadata is reverted after syncing
Given I have edited some of the resource's metadata (title, description or tags) after importing from <channel_b>
And I am at the *Sync resources* modal window
When I select the *Resource details* or *Titles and descriptions* checkbox
When I select the *Resource details* and *Titles and descriptions* checkboxes
And click the *Continue* button
Then I see the *Confirm sync* modal
When I click *Sync*
Then the modal closes
When after a period of time I refresh the page
And inspect the updated resource
Then I see that my previous edits of the title, description or tags for the resource have been reverted to reflect those on the <channel_b>
Then I see that my previous edits of the title, description or tags for the resource have been reverted to reflect those in <channel_b>
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Feature: Upload files
Then I see a file explorer window
When I select a supported file for upload
And I click the *Open* button
Then I see the *Edit files* modal
Then I see the *Edit files* modal #if I am uploading resources to a folder with metadata then I will first see the *Apply details from the folder <folder_name>*
When I fill in all the required fields
And I click the *Finish* button
Then I am returned to the main topic tree view
Expand All @@ -27,7 +27,7 @@ Feature: Upload files
Then I see a file explorer window
When I select several supported files for upload
And I click the *Open* button
Then I see the *Edit files* modal
Then I see the *Edit files* modal #if I am uploading resources to a folder with metadata then I will first see the *Apply details from the folder <folder_name>*
When I fill in all the required fields for each file
And I click the *Finish* button
Then I am returned to the main topic tree view
Expand All @@ -39,7 +39,7 @@ Feature: Upload files
Then I see a file explorer window
When I select several supported files for upload
And I click the *Open* button
Then I see the *Edit files* modal
Then I see the *Edit files* modal #if I am uploading resources to a folder with metadata then I will first see the *Apply details from the folder <folder_name>*
When I fill in all the required fields for each file
And I click the *Finish* button
Then I am returned to the main topic tree view
Expand All @@ -48,7 +48,7 @@ Feature: Upload files
Scenario: Upload more files by drag and drop
Given I am at the *Edit files* modal after having imported some files
When I drag and drop files
Then I see the *Edit files* modal
Then I see the *Edit files* modal with the newly uploaded files #if I am uploading resources to a folder with metadata then I will first see the *Apply details from the folder <folder_name>*
When I fill in all the required fields for each file
And I click the *Finish* button
Then I am returned to the main topic tree view
Expand All @@ -63,4 +63,4 @@ Feature: Upload files
Then I am back at the *Upload files* modal
When I close the modal
Then I am returned to the main topic tree view
And I can see the uploaded files are not present
And I can see the uploaded files are not present
Loading