docs(AGENTS): test-parametrization, serialization-test & architecture conventions#2921
Merged
Merged
Conversation
…tecture conventions Codify recurring maintainer review feedback so any agent (and human) working in this repo follows it up front: - Testing: use TestNG @dataProvider for near-identical cases instead of N methods; no issue-refs/narrative comments inside tests; serialization tests place the field under test mid-schema with a trailing fixed-width column and assert the whole row; prefer integration over unit-only tests for read-path behavior. - Architecture: value/parameter conversion belongs on the value-converter classes (reusable instance methods, no static formatters); transport receives already-formatted values; prefer an explicit stack over recursion for nested containers; read-path (DateTime/timezone) fixes belong in client-v2 BinaryStreamReader, not clickhouse-data ClickHouseColumn.
|
Repository collaborators can run the JMH benchmark suite against this PR by commenting: Optional regression threshold override (Δ% on Time or Alloc/op; defaults to 10%): Only one benchmark run per PR is active at a time — issuing a new |
polyglotAI-bot
marked this pull request as ready for review
July 13, 2026 11:41
chernser
approved these changes
Jul 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds three sets of conventions to
AGENTS.mdthat maintainers have asked for repeatedly in recent PR reviews, so every agent (and human contributor) applies them up front instead of during review round-trips.Testing expectations
@DataProvider(one parametrized test) instead of several near-identical test methods.Architecture conventions (new section)
ArrayDequestack over recursion for arbitrarily nested containers.DateTime/timezone) fixes belong inclient-v2BinaryStreamReader, notclickhouse-dataClickHouseColumn.Why
These mirror concrete review feedback on recent PRs (e.g. #2886, #2898, #2877): data-provider tests, "we do not reference issues or comment tests much", the mid-row serialization-test technique, converting unit tests to integration tests, the value-converter/transport separation, using a stack instead of recursion, and fixing the read path in
BinaryStreamReader.Docs-only change — no code or test behavior affected.
🤖 Generated with Claude Code