From 0a1dedeb03b648dc342b09f4734bddc0bae6173c Mon Sep 17 00:00:00 2001 From: Prarup Gurung Date: Tue, 8 Nov 2022 16:17:42 +0545 Subject: [PATCH] Refactored feature files to make consistent inter-scenarios space --- .../features/webUIActivityList/activityList.feature | 2 ++ .../features/webUITextEditor/createTextFiles.feature | 12 ++++++++++++ .../features/webUITextEditor/editTextFiles.feature | 1 + 3 files changed, 15 insertions(+) diff --git a/tests/acceptance/features/webUIActivityList/activityList.feature b/tests/acceptance/features/webUIActivityList/activityList.feature index 64dbcf28..99643445 100644 --- a/tests/acceptance/features/webUIActivityList/activityList.feature +++ b/tests/acceptance/features/webUIActivityList/activityList.feature @@ -9,6 +9,7 @@ Feature: log activity of actions done by the texteditor app And user "Alice" has logged in using the webUI And the user has browsed to the files page + Scenario: creating a new text file should be listed in the activity list Given the user has created a text file with the name "activityfile.txt" And the user has input "stuff" in the text area @@ -17,6 +18,7 @@ Feature: log activity of actions done by the texteditor app Then the activity number 1 should contain message "You changed activityfile.txt" in the activity page And the activity number 2 should contain message "You created activityfile.txt" in the activity page + Scenario: editing an existing text file should be listed in the activity list Given the user has opened file "lorem.txt" using the webUI And the user has input "changed text" in the text area diff --git a/tests/acceptance/features/webUITextEditor/createTextFiles.feature b/tests/acceptance/features/webUITextEditor/createTextFiles.feature index d3f0d570..93d64c51 100644 --- a/tests/acceptance/features/webUITextEditor/createTextFiles.feature +++ b/tests/acceptance/features/webUITextEditor/createTextFiles.feature @@ -9,6 +9,7 @@ Feature: textFiles And user "Alice" has logged in using the webUI And the user has browsed to the files page + Scenario Outline: Create a text file When the user creates a text file with the name using the webUI And the user inputs in the text area @@ -25,6 +26,7 @@ Feature: textFiles | '"somequotes1" text.txt' | 'John said,"hello."' | | "'somequotes2' text.txt" | 'special !@#$%^&*()[]{}\|-_+=\/?' | + Scenario: Create a text file with the default name and file extension When the user creates a text file with the name "" using the webUI And the user inputs "stuff" in the text area @@ -33,6 +35,7 @@ Feature: textFiles And the user reloads the current page of the webUI Then file "New text file.txt" should be listed on the webUI + Scenario: Create a text file with the default file extension and do not close the editor When the user creates a text file with the name "abc" using the webUI without changing the default file extension And the user inputs "something" in the text area @@ -40,6 +43,7 @@ Feature: textFiles And the user reloads the current page of the webUI Then file "abc.txt" should be listed on the webUI + Scenario: Create a text file with the default file extension and unicode file name When the user creates a text file with the name "सिमप्ले text file" using the webUI without changing the default file extension And the user inputs "नेपाल" in the text area @@ -51,6 +55,7 @@ Feature: textFiles Then there should be 1 line of text in the text area And line 1 of the text should be "नेपाल" + Scenario: Create a text file with multiple lines of text in it When the user creates a text file with the name "atextfile.txt" using the webUI And the user inputs the following text in the text area: @@ -75,6 +80,7 @@ Feature: textFiles And line 5 of the text should be "नेपाल" And line 6 of the text should be "1 2 3 4 5 6 7 8 9 0" + Scenario: Create a text file with the default name and file extension in a sub-folder When the user creates a folder with the name "simple-folder" using the webUI And the user opens folder "simple-folder" using the webUI @@ -87,6 +93,7 @@ Feature: textFiles And the user opens file "New text file.txt" using the webUI Then line 1 of the text should be "stuff" + Scenario: Create a text file in a sub-folder using special characters in the names When the user creates a folder with the name "सिमप्ले फोल्देर $%#?&@" using the webUI And the user opens folder "सिमप्ले फोल्देर $%#?&@" using the webUI @@ -97,22 +104,27 @@ Feature: textFiles And the user reloads the current page of the webUI Then file "सिमप्ले $%#?&@ name.txt" should be listed on the webUI + Scenario: Create a text file putting a name of a file which already exists When the user creates a text file with the name "lorem.txt" using the webUI Then near the new text file box a tooltip with the text 'lorem.txt already exists' should be displayed on the webUI + Scenario: Create a text file named with forward slash When the user creates a text file with the name "simple-folder/a.txt" using the webUI Then near the new text file box a tooltip with the text 'File name cannot contain "/".' should be displayed on the webUI + Scenario: Create a text file named .. When the user creates a text file with the name ".." using the webUI Then near the new text file box a tooltip with the text '".." is an invalid file name.' should be displayed on the webUI + Scenario: Create a text file named . When the user creates a text file with the name "." using the webUI Then near the new text file box a tooltip with the text '"." is an invalid file name.' should be displayed on the webUI + Scenario: Create a text file with file extension .part When the user creates a text file with the name "data.part" using the webUI Then near the new text file box a tooltip with the text '"data.part" has a forbidden file type/extension.' should be displayed on the webUI diff --git a/tests/acceptance/features/webUITextEditor/editTextFiles.feature b/tests/acceptance/features/webUITextEditor/editTextFiles.feature index bfb99d19..56a447f3 100644 --- a/tests/acceptance/features/webUITextEditor/editTextFiles.feature +++ b/tests/acceptance/features/webUITextEditor/editTextFiles.feature @@ -8,6 +8,7 @@ Feature: textFiles And user "Alice" has logged in using the webUI And the user has browsed to the files page + Scenario: Edit a text file with the default name and file extension in a sub-folder When the user creates a folder with the name "simple-folder" using the webUI And the user opens folder "simple-folder" using the webUI