Skip to content

Commit

Permalink
DynamoDB: Use CrateDB 5.8.3 for testing
Browse files Browse the repository at this point in the history
... because 5.8.4 can no longer store `ARRAY`s with varying inner types
into `OBJECT(IGNORED)` columns.
  • Loading branch information
amotl committed Oct 9, 2024
1 parent 548b137 commit 7320082
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 3 deletions.
3 changes: 3 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Changelog

## Unreleased
- MongoDB: Fixed BSON decoding of `{"$date": 1180690093000}` timestamps
- DynamoDB: Use CrateDB 5.8.3 for testing because 5.8.4 can no longer
store `ARRAY`s with varying inner types into `OBJECT(IGNORED)` columns.

## 2024/09/30 v0.0.20
- DynamoDB: Change CrateDB data model to use (`pk`, `data`, `aux`) columns
Expand Down
19 changes: 16 additions & 3 deletions tests/transform/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,25 @@


@pytest.fixture(scope="function")
def cratedb(cratedb_service):
def cratedb_custom_service():
"""
Provide a CrateDB service instance to the test suite.
"""
from cratedb_toolkit.testing.testcontainers.cratedb import CrateDBTestAdapter

db = CrateDBTestAdapter(crate_version="5.8.3")
db.start()
yield db
db.stop()


@pytest.fixture(scope="function")
def cratedb(cratedb_custom_service):
"""
Provide a fresh canvas to each test case invocation, by resetting database content.
"""
cratedb_service.reset(tables=RESET_TABLES)
yield cratedb_service
cratedb_custom_service.reset(tables=RESET_TABLES)
yield cratedb_custom_service


@pytest.fixture
Expand Down

0 comments on commit 7320082

Please sign in to comment.