Charm testing

Charmed MongoDB development supports software unit tests, integration tests, and performance tests.

Unit tests

See CONTRIBUTING.md and follow the tox examples

Integration tests

Integration test coverage is quite rich in MongoDB charms. When it comes to complex features and HA (High Availability), each test serves as an integration as well as a smoke test with continuous writes routines being perpetually ran in parallel of whatever operation the test is involved in.

These continuous writes ensure the availability of the service under different conditions. These tests make use of the following fixture:

  • continuous_writes_to_db: creates a replicated collection and continuously stores data into it.

After each test completes, the collection gets deleted.

Performance tests

See the following guides (external links):