[ Index ]

PHP Cross Reference of Unnamed Project

title

Body

[close]

/mod/survey/tests/behat/ -> survey_completion.feature (source)

   1  @mod @mod_survey
   2  Feature: A teacher can use activity completion to track a student progress
   3    In order to use activity completion
   4    As a teacher
   5    I need to set survey activities and enable activity completion
   6  
   7    Background:
   8      Given the following "users" exist:
   9        | username | firstname | lastname | email |
  10        | teacher1 | Teacher | 1 | teacher1@example.com |
  11      And the following "courses" exist:
  12        | fullname | shortname | category | enablecompletion |
  13        | Course 1 | C1 | 0 | 1 |
  14      And the following "course enrolments" exist:
  15        | user | course | role |
  16        | teacher1 | C1 | editingteacher |
  17      And I log in as "teacher1"
  18      And I follow "Course 1"
  19      And I turn editing mode on
  20  
  21    Scenario: Require survey view
  22      Given I add a "Survey" to section "1" and I fill the form with:
  23        | Name | Test survey name |
  24        | Survey type | Critical incidents |
  25        | Description | Test survey description |
  26        | Completion tracking | Show activity as complete when conditions are met |
  27        | id_completionview | 1 |
  28      And I turn editing mode off
  29      And the "Test survey name" "survey" activity with "auto" completion should be marked as not complete
  30      When I follow "Test survey name"
  31      And I follow "Course 1"
  32      Then the "Test survey name" "survey" activity with "auto" completion should be marked as complete
  33  
  34    Scenario: Require survey submission
  35      Given I add a "Survey" to section "1" and I fill the form with:
  36        | Name | Test survey name |
  37        | Survey type | Critical incidents |
  38        | Description | Test survey description |
  39        | Completion tracking | Show activity as complete when conditions are met |
  40        | id_completionsubmit | 1 |
  41      And I turn editing mode off
  42      And the "Test survey name" "survey" activity with "auto" completion should be marked as not complete
  43      When I follow "Test survey name"
  44      And I press "Click here to continue"
  45      And I follow "Course 1"
  46      Then the "Test survey name" "survey" activity with "auto" completion should be marked as complete


Generated: Thu Aug 11 10:00:09 2016 Cross-referenced by PHPXref 0.7.1