Skip to main content

Integration tests

Integration Testing is used to test use cases and multiple components together. We have 5 use cases, and these are the tests for each of them.

test_github_with_discord (Use case #1):

Test: Tests whether CollabyBot can attach to a test GitHub repository, connect to Discord server, and is able receive repository updates through webhooks and send it to Discord
Returns: True if the test was successful, otherwise returns false


Uses:
github component: test_github_webhook_creation
database component: test_database_connection
test_database_store_notification
test_database_get_notification
discord bot component: to be decided/added

test_tasklist_discord (Use Case #2)​

Test: Tests whether a Collaby Bot user is able to create a personal task list with reminders through discord bot command.
Returns: True if task list was created and stored in the database successfully, otherwise returns false
Uses: discord bot component and database component
Mock Input of discord bot command: “/todo new Eat,Sleep,Code,Repeat 10/11/2022”

test_jira_discord (Use Case #3​)

Test: Tests if Collaby Bot user is able to get information about their team’s progress on Jira tasks as a message/notification in separate channel for Jira, by granting Collaby Bot access to Jira
Returns: true if granting access to Jira and receiving Jira notification was successful, otherwise returns false
Uses: discord bot component, jira component

test_github_setitings (Use Case #4)

Test: Tests if a collaby bot user is able to choose what updates to receive about their GitHub repository, by sending discord bot command “github events” command and responding with a list of available event types
Returns: True if the list of the available commands was truly saved and is acting as a filter, otherwise returns false
Uses: discord bot component, database component(to save settings) and github component

test_github_events_search_commit_discord (Use Case #5​)

Test: Tests Github Repository Events Search for commits only, through discord bot command
Returns: True if the response contains all expected commits(data), false otherwise.
Uses: discord bot component, database component