Integration tests

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2020-12-30 17:02:25 +01:00
parent db2ceae720
commit 609a7b275f
11 changed files with 438 additions and 206 deletions

View File

@@ -10,27 +10,36 @@ Feature: acl
And group "group1" exists
Given user "user1" belongs to group "group1"
Scenario: Request the main frontend page
Given Logging in using web as "user0"
When Sending a "GET" to "/index.php/apps/deck" without requesttoken
Then the HTTP status code should be "200"
Scenario: Fetch the board list
Given Logging in using web as "user0"
When Sending a "GET" to "/index.php/apps/deck/boards" with requesttoken
Then the HTTP status code should be "200"
And the Content-Type should be "application/json; charset=utf-8"
When fetching the board list
Then the response should have a status code "200"
And the response Content-Type should be "application/json; charset=utf-8"
Scenario: Fetch board details of owned board
Given Logging in using web as "admin"
And creates a board named "MyPrivateAdminBoard" with color "fafafa"
When "admin" fetches the board named "MyPrivateAdminBoard"
Then the HTTP status code should be "200"
And the Content-Type should be "application/json; charset=utf-8"
When fetches the board named "MyPrivateAdminBoard"
Then the response should have a status code "200"
And the response Content-Type should be "application/json; charset=utf-8"
Scenario: Fetch board details of an other users board
Given Logging in using web as "admin"
And creates a board named "MyPrivateAdminBoard" with color "fafafa"
When "user0" fetches the board named "MyPrivateAdminBoard"
Then the HTTP status code should be "403"
And the Content-Type should be "application/json; charset=utf-8"
Given Logging in using web as "user0"
When fetches the board named "MyPrivateAdminBoard"
Then the response should have a status code "403"
And the response Content-Type should be "application/json; charset=utf-8"
Scenario: Share a board
Given Logging in using web as "user0"
And creates a board named "Shared board" with color "fafafa"
And shares the board with user "user1"
Then the HTTP status code should be "200"
Given Logging in using web as "user1"
When fetches the board named "Shared board"
And the current user should have read permissions on the board
And the current user should have write permissions on the board
And the current user should have share permissions on the board
And the current user should have manage permissions on the board
Then the HTTP status code should be "200"