Summary
The Rust client at crates/clickhouse-cloud-api/ exposes 100 async methods. The live integration tests in tests/integration_test.rs (service CRUD) and tests/integration_postgres_test.rs (postgres CRUD) exercise 25 of them. The other 75 are mock-tested in tests/client_test.rs only, which catches request-shape regressions but not live API drift.
The mock tests + scripts/check-openapi-drift.py will tell us when the spec moves. They won't tell us when a method that compiles locally returns 4xx in production. As clickhousectl ships more cloud commands, this gap turns into runtime errors for end users.
This issue groups the work to close that gap.
Strategy
- Three test binaries, one per resource shape:
integration_org_test.rs (new) — org-scoped endpoints, no service provisioning.
integration_test.rs (extend) — endpoints needing one ClickHouse service.
integration_postgres_test.rs (extend) — endpoints needing one Postgres service.
- Each binary = one
#[tokio::test] lifecycle with FailureRecorder accumulating non-blocking failures so a single run reports every broken endpoint, not just the first.
- Always run all three on every PR. Path-based selection deferred.
- Failure policy: NonBlocking by default; Blocking only when downstream phases depend on the step.
Scope
Bootstrap
Org suite (depends on #152)
Service suite (extends integration_test.rs)
Postgres suite (extends integration_postgres_test.rs)
Separate
Out of scope this round
Fixtures required
- Existing second user in the test org (already present).
- New env var
CLICKHOUSE_CLOUD_TEST_SECONDARY_USER_ID — that user's id.
- Invitations sent to
alasdair.brown+clickhousectl_{run_id}@clickhouse.com (catch-all alias, cancelled before accept).
Today's coverage
25/100 client methods covered live. The remaining gap is enumerated across the linked child issues; closing every in-scope issue brings live coverage to 35 of the 100 methods, with the other 65 categorised under "Out of scope this round" above.
Summary
The Rust client at
crates/clickhouse-cloud-api/exposes 100 async methods. The live integration tests intests/integration_test.rs(service CRUD) andtests/integration_postgres_test.rs(postgres CRUD) exercise 25 of them. The other 75 are mock-tested intests/client_test.rsonly, which catches request-shape regressions but not live API drift.The mock tests +
scripts/check-openapi-drift.pywill tell us when the spec moves. They won't tell us when a method that compiles locally returns 4xx in production. Asclickhousectlships more cloud commands, this gap turns into runtime errors for end users.This issue groups the work to close that gap.
Strategy
integration_org_test.rs(new) — org-scoped endpoints, no service provisioning.integration_test.rs(extend) — endpoints needing one ClickHouse service.integration_postgres_test.rs(extend) — endpoints needing one Postgres service.#[tokio::test]lifecycle withFailureRecorderaccumulating non-blocking failures so a single run reports every broken endpoint, not just the first.Scope
Bootstrap
integration_org_test.rsskeleton + secondary-user fixtureOrg suite (depends on #152)
Service suite (extends
integration_test.rs)Postgres suite (extends
integration_postgres_test.rs)Separate
Out of scope this round
postgres_instance_restore).member_delete/ member accept — would kick our test fixture or are UI-only flows.Fixtures required
CLICKHOUSE_CLOUD_TEST_SECONDARY_USER_ID— that user's id.alasdair.brown+clickhousectl_{run_id}@clickhouse.com(catch-all alias, cancelled before accept).Today's coverage
25/100 client methods covered live. The remaining gap is enumerated across the linked child issues; closing every in-scope issue brings live coverage to 35 of the 100 methods, with the other 65 categorised under "Out of scope this round" above.