Skip to content

Testing

Kristian Vestbø edited this page Apr 24, 2026 · 3 revisions

Testing

Overview

The application has a total of 80 tests, all of which pass. Testing was done using JUnit, and covers the majority of the codebase including core logic and database behavior. Testing the application is useful to prove that defects exist, not that the project is error-free. The goal is to identify as many errors as possible. Testing should start as early as possible, this is called test driven development (TDD). This is done to spare time and makes for better cohesion.

Running the Tests

To run all tests, execute the following command in the root of the project:

mvn test

Results will be printed in the terminal. All 80 tests should pass with no failures.

Unit Tests

Unit tests were written using JUnit to cover the core logic of the application. The goal was to test as much of the codebase as possible in isolation, verifying that individual methods and classes behave correctly on their own.

Integration Tests

Integration tests were written to verify the database layer of the application. These tests check that the full flow of data works correctly — for example that users, organizations, and donations are saved to and retrieved from the SQLite database as expected.

Test Coverage

Type What is tested
Unit tests Core application logic and methods
Integration tests Database flow and behavior
Manual tests UI navigation and usability (see Usability Tests)
Clone this wiki locally