Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
@core @core_backup
2
Feature: Duplicate activities
3
  In order to set up my course contents quickly
4
  As a teacher
5
  I need to duplicate activities inside the same course
6
 
7
  Scenario: Duplicate an activity
8
    Given the following "course" exists:
9
      | fullname     | Course 1 |
10
      | shortname    | C1       |
11
      | category     | 0        |
12
      | initsections | 1        |
13
    And the following "users" exist:
14
      | username | firstname | lastname | email |
15
      | teacher1 | Teacher | 1 | teacher1@example.com |
16
    And the following "course enrolments" exist:
17
      | user | course | role |
18
      | teacher1 | C1 | editingteacher |
19
    And the following "activities" exist:
20
      | activity | name               | intro                     | course | idnumber   | section |
21
      | data     | Test database name | Test database description | C1     | database1  | 1       |
22
    And the following config values are set as admin:
23
      | backup_import_activities | 0 | backup |
24
    And I log in as "teacher1"
25
    And I am on "Course 1" course homepage with editing mode on
26
    And I duplicate "Test database name" activity
27
    And I should see "Test database name (copy)"
28
    And I wait until section "1" is available
29
    And I click on "Edit settings" "link" in the "Test database name" activity
30
    And I set the following fields to these values:
31
      | Name | Original database name |
32
    And I press "Save and return to course"
33
    And I click on "Edit settings" "link" in the "Test database name (copy)" activity
34
    And I set the following fields to these values:
35
      | Name | Duplicated database name |
36
      | Description | Duplicated database description |
37
    And I press "Save and return to course"
38
    Then I should see "Original database name" in the "Section 1" "section"
39
    And I should see "Duplicated database name" in the "Section 1" "section"
40
    And "Original database name" "link" should appear before "Duplicated database name" "link"