Skip to content

Conversation

@blathers-crl
Copy link

@blathers-crl blathers-crl bot commented Sep 8, 2025

Backport 1/1 commits from #152880 on behalf of @nicktrav.


Fix a testing bug introduced in #131545 where the Contains check arguments were reversed. The error string being searched should precede the string being searched for. The examples from the API docs:

//	require.Contains(t, "Hello World", "World")
//	require.Contains(t, ["Hello", "World"], "World")
//	require.Contains(t, {"Hello": "World"}, "Hello")

Release note: None

Epic: None


Release justification: Test only.

Fix a testing bug introduced in #131545 where the `Contains` check
arguments were reversed. The error string being _searched_ should
precede the string being _searched for_. The examples from the API docs:

```
//	require.Contains(t, "Hello World", "World")
//	require.Contains(t, ["Hello", "World"], "World")
//	require.Contains(t, {"Hello": "World"}, "Hello")
```

Release note: None
@blathers-crl blathers-crl bot requested a review from a team as a code owner September 8, 2025 23:53
@blathers-crl blathers-crl bot force-pushed the blathers/backport-release-25.2-152880 branch from 8a11c98 to 4aeb100 Compare September 8, 2025 23:53
@blathers-crl blathers-crl bot requested review from asg0451 and removed request for a team September 8, 2025 23:53
@blathers-crl blathers-crl bot added blathers-backport This is a backport that Blathers created automatically. O-robot Originated from a bot. labels Sep 8, 2025
@blathers-crl
Copy link
Author

blathers-crl bot commented Sep 8, 2025

Thanks for opening a backport.

Before merging, please confirm that it falls into one of the following categories (select one):

  • Non-production code changes. Includes test-only changes, build system changes, etc.
  • Fixes for serious issues. Defined in the policy as correctness, stability, or security issues, data corruption/loss, significant performance regressions, breaking working and widely used functionality, or an inability to detect and debug production issues.
  • Other approved changes. These changes must be gated behind a disabled-by-default feature flag unless there is a strong justification not to.

Add a brief release justification to the PR description explaining your selection.

Also, confirm that the change does not break backward compatibility and complies with all aspects of the backport policy.

All backports must be reviewed by the TL and EM for the owning area.

@blathers-crl blathers-crl bot added the backport Label PR's that are backports to older release branches label Sep 8, 2025
@blathers-crl
Copy link
Author

blathers-crl bot commented Sep 8, 2025

✅ PR #153210 is compliant with backport policy

Confidence: high
Backward compatible: true
Explanation: The pull request is compliant with backport policy because the changes are limited to a non-production file classified under the test file patterns (*_test.go). The PR specifically modifies a file named 'errors_test.go', which, according to the defined CockroachDB backport policy, exempts it from requiring gating behind a feature flag or critical bug fixes since it only affects test logic. Additionally, the PR body mentions 'Release justification: Test only.' which further aligns with the policy allowances for testing-related changes. As the changes pertain solely to test logic correction (specifically checking argument order in assertions), there is no implication on production code, no feature flag requirement, and the changes inherently maintain backward compatibility.

🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf.

@blathers-crl blathers-crl bot added the backport-test-only Used to denote the backport has only non-production changes label Sep 9, 2025
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@aerfrei aerfrei self-requested a review September 10, 2025 15:52
@nicktrav
Copy link
Collaborator

TFTR!

@nicktrav nicktrav merged commit 0e35b2b into release-25.2 Sep 10, 2025
16 checks passed
@nicktrav nicktrav deleted the blathers/backport-release-25.2-152880 branch September 10, 2025 15:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport Label PR's that are backports to older release branches backport-test-only Used to denote the backport has only non-production changes blathers-backport This is a backport that Blathers created automatically. O-robot Originated from a bot. v25.2.7

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants