diff --git a/database/schemas/mongo.py b/database/schemas/mongo.py index d065bd4..aeced32 100644 --- a/database/schemas/mongo.py +++ b/database/schemas/mongo.py @@ -103,7 +103,7 @@ class GameStats(MongoCollection): class WordleGame(MongoCollection): """Collection that holds people's active Wordle games""" - day: datetime.date = Field(default_factory=lambda: today_only_date()) + day: datetime.datetime = Field(default_factory=lambda: today_only_date()) guesses: list[str] = Field(default_factory=list) user_id: int diff --git a/docker-compose.test.yml b/docker-compose.test.yml index a446613..064d93b 100644 --- a/docker-compose.test.yml +++ b/docker-compose.test.yml @@ -17,5 +17,6 @@ services: - MONGO_INITDB_ROOT_USERNAME=pytest - MONGO_INITDB_ROOT_PASSWORD=pytest - MONGO_INITDB_DATABASE=didier_pytest + command: [--auth] ports: - "27018:27017" diff --git a/readme.md b/readme.md index 1060271..e2340c6 100644 --- a/readme.md +++ b/readme.md @@ -30,10 +30,10 @@ A separate database is used in the tests, as it would obviously not be ideal whe ```shell # Starting the database -docker-compose up -d db +docker compose up -d # Starting the database used in tests -docker-compose up -d db-pytest +docker compose -f docker-compose.test.yml up -d ``` ### Commands