nromanen / pratical_testing_2022

0 stars 2 forks source link

Changed request to #2551. Edit "To-do list" #191

Open machechka opened 1 year ago

machechka commented 1 year ago

As a user, I want to edit my "To-do list" so that I could add or delete items if needed.

Preconditions:

  1. The registered user is logged in.
  2. User has at least 1 habit in progress.

Acceptance criteria:

System displays items in the "To-do list" in the following order:

  1. selected items while adding a habit by a user are displayed at the top of the list with the “-” button;
  2. recommended by the system items that weren’t selected by a user are displayed with the “+” button;
  3. at the bottom of the list user sees the input field with “+” button;
  4. system displays 3 items by default;
  5. when user want to see more items he/she can use the "scrollbar" on the right side of the text;
  6. when user hovers a cursor over the item, the system displays the whole item’s name;
  7. recommended by the system items are displayed in alphabetical order.

When there are no recommended items in the "To-do list":

User can remove an item from the "To-do list" by clicking on the “-” button.

User can add an item from the recommended list by clicking on the “+” button.

User can add his/her custom item: according to the user stories: https://github.com/ita-social-projects/GreenCity/issues/2251, https://github.com/ita-social-projects/GreenCity/issues/2249

  1. user should type the item's name into the input field by clicking ENTER or the “+” button;
  2. the custom item is displayed on the top of the "To-do list" with the “+” button;
  3. if the user wants to add his created custom item to the "To-do list", he/she should click on the "+" button;
  4. user can remove the custom item by clicking on the "x" button on the right side of the item's name;
  5. user can't type less than 3 characters into the input field. The "+" button is not activated;
  6. the input field should contain no more than 50 characters (all characters, except: @!#$%^*()_+-{}[]?><:";,.\'|/~`§=space);
  7. when the user type more than 50 characters, the message "The input field should contain no more than 50 characters" highlighted in red is displayed under the input field. The '+' button in not activated.
  8. user is able to type a link in the input field which should be clickable on the "Habits" page.

When user click on the “Save” button:

  1. the system updates changes in the "To-do list" on the "Habits" page (edit mode) and in the "My To-do list" on the left side bottom of the "My habits" page;
  2. the system is displayed a pop-up window with the text highlighted in green “You have successfully updated a habit” and returns user to "My habits" page.