Scenario: Create a blog post
Given that I am asked to add a blog
When I give the details of title/content/date that are needed
Then blog creates successfully with a message "New blog entry added!"
Scenario: Create a blog without any information
Given that I am asked to add a blog
When I don't give the details of Title/Description/Author that are needed
Then blog gives an error message "Title/Description/Author is empty, try write something"
-printListOfBlogs
Scenario: List all blog posts that has been added before
Given that I type in 2 in the menu
When there is any blog information in Arraylist
Then I will see full list of blogs that has been created with all its information
such as ID/Title/Description/Author
Scenario: Listing when the list is empty
Given that I type in 2 in the menu
When no blogs have been added at all before
Then I will receive a message "No blogs in the list... " in the Client
updateBlog
Scenario: Updating blog by ID that exists
Given that I am asked to type in the blog ID I want to change
Given that I am asked to pick Title/Description/Author to change
When I give the new details of either Title/Description/Author
Then blog will be updated successfully and HTTP status code will show 200
Scenario: Updating blog by ID that does not exist
Given that I am asked to type in 3 in the menu
Given that I am asked to type in the blog ID I want to change
When I type in an ID that does not exist
Then I will receive HTTP status code 404 with message "Issue updating Blog" from the Client
and "There is no Blog with id ' " + id +" ' in the list." from the Server
_searchBlogByID
Scenario: Finding/searching for an ID within the list
Given that I am asked to type in the blog ID I want to find
When I type in whatever ID that I know exist within the blog list
Then that blog will be displayed with all its information such as Title/Description/Author
HTTP status will be shown 200 with message "Here is the blog you wanted" from the Client
Scenario: Finding/searching for an ID that does not exist within the list
Given that I am asked to type in the blog ID I want to find
When I type in whatever ID that does not exist within the blog list
Then HTTP status code will be 404 with a message "Issue finding the blog you wanted"
from the Client and "The Blog you want does not exist " on the Server
_deleteBlogById
Scenario: Deleting blog by ID that exists
Given that I am asked to type in 5 on menu
Given I type in the ID number that exists in the list
When I type in the ID number that exists in the list
Then blog successfully deletes the blog with message "Blog with id X has now been deleted"
from the Client and the Server
Scenario: Deleting blog by ID that does not exist
Given that I am asked to type in 5 in menu
Given that I am asked to type in the Blog ID to remove
When I type in the ID number that does not exist in the list
Then HTTP status code will display 404 and display "There is no Blog with id X in the list." from the Client and "There is no blog with id"
from the Server
_deleteAllblogs
Scenario: Clearing the list of all blog post that has been added before
Given that I type in 6 in the menu
When all blogs will be removed successfully and the blog list will be emptied
Then I will receive a message saying "Clearing list Successfully" from the Client and "The Blog list is cleared!!!" from the Server
Scenario: Clearing the list of blog post when Server is not connected
Given that I type in 6 in the menu
When the server is not connected
Then I will receive a message saying "Issue clearing list of blogs"
-addBlog
Scenario: Create a blog post Given that I am asked to add a blog When I give the details of title/content/date that are needed Then blog creates successfully with a message "New blog entry added!"
Scenario: Create a blog without any information
Given that I am asked to add a blog
When I don't give the details of Title/Description/Author that are needed
Then blog gives an error message "Title/Description/Author is empty, try write something"
-printListOfBlogs
Scenario: List all blog posts that has been added before
Given that I type in 2 in the menu
When there is any blog information in Arraylist
Then I will see full list of blogs that has been created with all its information such as ID/Title/Description/Author
Scenario: Listing when the list is empty
Given that I type in 2 in the menu
When no blogs have been added at all before
Then I will receive a message "No blogs in the list... " in the Client
updateBlog
Scenario: Updating blog by ID that exists
Given that I am asked to type in the blog ID I want to change
Given that I am asked to pick Title/Description/Author to change
When I give the new details of either Title/Description/Author
Then blog will be updated successfully and HTTP status code will show 200
Scenario: Updating blog by ID that does not exist
Given that I am asked to type in 3 in the menu
Given that I am asked to type in the blog ID I want to change
When I type in an ID that does not exist
Then I will receive HTTP status code 404 with message "Issue updating Blog" from the Client and "There is no Blog with id ' " + id +" ' in the list." from the Server
_searchBlogByID
Scenario: Finding/searching for an ID within the list
Given that I am asked to type in the blog ID I want to find
When I type in whatever ID that I know exist within the blog list
Then that blog will be displayed with all its information such as Title/Description/Author
HTTP status will be shown 200 with message "Here is the blog you wanted" from the Client
Scenario: Finding/searching for an ID that does not exist within the list
Given that I am asked to type in the blog ID I want to find
When I type in whatever ID that does not exist within the blog list
Then HTTP status code will be 404 with a message "Issue finding the blog you wanted" from the Client and "The Blog you want does not exist " on the Server
_deleteBlogById
Scenario: Deleting blog by ID that exists
Given that I am asked to type in 5 on menu
Given I type in the ID number that exists in the list
When I type in the ID number that exists in the list
Then blog successfully deletes the blog with message "Blog with id X has now been deleted" from the Client and the Server
Scenario: Deleting blog by ID that does not exist
Given that I am asked to type in 5 in menu
Given that I am asked to type in the Blog ID to remove
When I type in the ID number that does not exist in the list
Then HTTP status code will display 404 and display "There is no Blog with id X in the list." from the Client and "There is no blog with id" from the Server
_deleteAllblogs
Scenario: Clearing the list of all blog post that has been added before
Given that I type in 6 in the menu
When all blogs will be removed successfully and the blog list will be emptied
Then I will receive a message saying "Clearing list Successfully" from the Client and "The Blog list is cleared!!!" from the Server
Scenario: Clearing the list of blog post when Server is not connected
Given that I type in 6 in the menu
When the server is not connected
Then I will receive a message saying "Issue clearing list of blogs"