Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
@mod @mod_forum @javascript
2
Feature: Students can reply to a discussion in page.
3
 
4
  Background:
5
    Given the following "users" exist:
6
      | username | firstname | lastname | email |
7
      | student1 | Student | 1 | student1@example.com |
8
      | teacher1 | Teacher | 1 | teacher1@example.com |
9
    And the following "courses" exist:
10
      | fullname | shortname | category |
11
      | Course 1 | C1 | 0 |
12
    And the following "course enrolments" exist:
13
      | user | course | role |
14
      | student1 | C1 | student |
15
      | teacher1 | C1 | editingteacher |
16
    And the following "activity" exists:
17
      | activity    | forum                  |
18
      | course      | C1                     |
19
      | idnumber    | 0001                   |
20
      | name        | Test forum name        |
21
    And the following "mod_forum > discussions" exist:
22
      | forum | course | user     | name         | message                              |
23
      | 0001  | C1     | teacher1 | Discussion 1 | Discussion contents 1, first message |
24
      | 0001  | C1     | teacher1 | Discussion 2 | Discussion contents 2, first message |
25
 
26
  Scenario: Confirm inpage replies work
27
    Given I am on the "Course 1" course page logged in as student1
28
    When I reply "Discussion 2" post from "Test forum name" forum using an inpage reply with:
29
      | post | Discussion contents 1, third message |
30
    Then I should see "Discussion contents 1, third message"
31
    And I reload the page
32
    And I should see "Discussion contents 1, third message"
33
 
34
  Scenario: Confirm inpage replies work - private reply
35
    Given I am on the "Course 1" course page logged in as teacher1
36
    When I reply "Discussion 2" post from "Test forum name" forum using an inpage reply with:
37
      | post | Discussion contents 1, third message |
38
      | privatereply | 1                            |
39
    Then I should see "Discussion contents 1, third message"
40
    And I should see "This is a private reply. (Teachers and other users with the capability to view private replies can also see it.)"
41
    And I reload the page
42
    And I should see "Discussion contents 1, third message"