Skip to content

Commit 89cac1d

Browse files
authored
993 progress: two more files converted to pytest, one remaining (#1535)
* 993 pull out constants to module scope * 993 convert assertions in test_storage.py * 993 convert a test * 993 convert a test using conftest fixture * 993 convert test_validate_storage to pytest * 993 easy test conversion * 993 convert remainder of tests in ItemStorageExtensionTest * 993 refactor test classes as a prelude to declassing * 993 convert a test from StorageExtensionSummariesTest * 993 rename for clarity post-declass * 993 declass StorageExtensionSummariesTest tests * 993 finish declassing * 993 declass AssetStorageExtensionTest * 993 finish declassing * 993 better names for asset tests * 993 start on test_timestamps.py * 993 replace assertions * 993 relocate cassettes prior to declassing * 993 set up for test conversion * 993 yet another nonfunctional declassing * 993 convert tests to pytest * 993 convert TimestampsSummariesTest * 993 ruff's opinions
1 parent 2960662 commit 89cac1d

12 files changed

+617
-679
lines changed

tests/conftest.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,14 @@ def collection() -> Catalog:
2626
return Collection("test-collection", "A test collection", ARBITRARY_EXTENT)
2727

2828

29+
@pytest.fixture
30+
def multi_extent_collection() -> Collection:
31+
# TODO this code is repeated many times; refactor to use this fixture
32+
return Collection.from_file(
33+
TestCases.get_path("data-files/collections/multi-extent.json")
34+
)
35+
36+
2937
@pytest.fixture
3038
def item() -> Item:
3139
return Item("test-item", ARBITRARY_GEOM, ARBITRARY_BBOX, datetime.now(), {})

0 commit comments

Comments
 (0)