Coverage for app / backend / src / tests / test_dummy_data.py: 100%
8 statements
« prev ^ index » next coverage.py v7.13.2, created at 2026-02-03 06:18 +0000
« prev ^ index » next coverage.py v7.13.2, created at 2026-02-03 06:18 +0000
1from couchers.db import session_scope
2from couchers.resources import copy_resources_to_database
3from dummy_data import add_dummy_data
6def test_add_dummy_data(db, caplog, testconfig):
7 # copy the real resources to the database: this way if the testing resources go out of date with the real ones
8 # causing dummy data to fail, we'll catch it easily
9 with session_scope() as session:
10 copy_resources_to_database(session)
12 add_dummy_data()
13 assert len(caplog.records) == 0