Commit 7f849217 authored by Rebecca Blundell's avatar Rebecca Blundell Committed by Robert Lyon
Browse files

Bug 1755662: Behat: test for renaming file

Change-Id: I13c0aca31565578444f0aca4a8865a06d9334fb8
(cherry picked from commit e62f774a)
parent 6ac82c72
Loading
Loading
Loading
Loading
+23 −0
Original line number Diff line number Diff line
@javascript @core
Feature: Rename file and add description
    As a user
    I want to be able to rename files and add descriptions
    So that I can manage my content

Background:
Given the following "users" exist:
    | username | password | email | firstname | lastname | institution | authname | role |
    | UserA | Kupuh1pa! | UserA@example.org | Angela | User | mahara | internal | member |

Scenario: Add file, rename and add description
    Given I log in as "UserA" with password "Kupuh1pa!"
    And I choose "Files" in "Content" from main menu
    And I attach the file "mahara_about.pdf" to "File"
    And I press "Edit \"mahara_about.pdf\""
    And I set the field "Name" to "renamed.pdf"
    And I set the field "Description" to "I hope I can see my saved changes"
    And I press "Save changes"
    And I should see "renamed.pdf"
    And I should see "I hope I can see my saved changes"
    And I reload the page
    And I should not see "mahara_about.pdf"