Full coverage for database.py