Goal
End-to-end integration test for cmd/ingestion full-import against a real Postgres/PostGIS container. The walking skeleton (#57) has no test coverage of the wired pipeline today.
Tracking under #10.
Scope
- Build-tag
integration, consistent with other integration tests in this repo (per CLAUDE.md).
- Use
testcontainers-go for Postgres/PostGIS, consistent with internal/testhelpers/.
- Use a tiny fixture
.osm.pbf (a handful of nodes, mix of POIs and non-POIs) checked into the repo under testdata/.
- Run the full pipeline (
osm.StreamNodes → Evaluate → TransformNode → UpsertBatch).
- Assert:
- Only nodes matching
osm.Evaluate land in places.
Place.Geometry, Tags, Rank are populated correctly for a known fixture node.
- Re-running
full-import on the same fixture is a no-op on row count (idempotency via (osm_id, osm_type) conflict key).
Out of scope
diff-sync testing (covered in its own issue).
- Performance / load testing.
Acceptance
- New file under
cmd/ingestion/ (e.g. full_import_integration_test.go) with the integration build tag.
go test -tags integration ./cmd/ingestion/... passes locally and in CI.
- Fixture
.osm.pbf is small (< 50 KB) and version-controlled.
Goal
End-to-end integration test for
cmd/ingestion full-importagainst a real Postgres/PostGIS container. The walking skeleton (#57) has no test coverage of the wired pipeline today.Tracking under #10.
Scope
integration, consistent with other integration tests in this repo (perCLAUDE.md).testcontainers-gofor Postgres/PostGIS, consistent withinternal/testhelpers/..osm.pbf(a handful of nodes, mix of POIs and non-POIs) checked into the repo undertestdata/.osm.StreamNodes→Evaluate→TransformNode→UpsertBatch).osm.Evaluateland inplaces.Place.Geometry,Tags,Rankare populated correctly for a known fixture node.full-importon the same fixture is a no-op on row count (idempotency via(osm_id, osm_type)conflict key).Out of scope
diff-synctesting (covered in its own issue).Acceptance
cmd/ingestion/(e.g.full_import_integration_test.go) with theintegrationbuild tag.go test -tags integration ./cmd/ingestion/...passes locally and in CI..osm.pbfis small (< 50 KB) and version-controlled.