richiebachala commented on issue #2044: URL: https://github.com/apache/iceberg-go/issues/2044#issuecomment-6718591127
Follow-up plan for the testkit, moved here from #2376 for tracking, as @laskoviymishka asked. The first PR (#2376) covers config, namespaces, tables, rename, register and commit, and runs the REST `catalogtest` suite in plain `go test`. **What uses it.** The existing `catalog/rest` unit tests stay as they are. `rest_test.go` and similar files pin exact wire payloads, headers and error-type fallbacks, such as `TestRenameTable404UntypedFallsBackToNoSuchTable`, and canned responses are the right tool for that. `resttest` is for things that need real state across calls: - the REST `catalogtest` run; - cross-catalog contract cases; - client flows such as commit conflict and retry, staged create then commit, and rename then load; - downstream projects that want a REST catalog in tests. **What stays on Docker.** Everything in `go-integration.yml`: the Spark 3.5 and 4.0 interop runs against the fixture and MinIO, and the Polaris external-REST run. Those check behaviour against real servers and object storage. **Proposed order after #2376:** 1. `catalogtest` cases for the #2100 contract: a terminal requirement doesn't match `ErrCommitFailed`, and a stale append lands with retries on. These run against every catalog, including `resttest`. 2. Views lifecycle, with matching `catalogtest` view cases. 3. `transactions/commit`. 4. Fault-injection options, such as failing the next commit with a 409 or 503, to reach the retry and unknown-commit-state paths the package doc says aren't exercised today. 5. Pagination. **`planfake`.** I'd keep it separate. It replays scripted responses for exact scan-planning sequences, polling and cancellation, while `resttest` keeps catalog state. If remote planning ever needs real table state, `resttest` could grow a planning hook. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
