Skip to content

🌱 Bump github.com/maxbrunsfeld/counterfeiter/v6 from 6.12.2 to 6.13.0 - #3916

Merged
openshift-merge-bot[bot] merged 2 commits into
masterfrom
dependabot/go_modules/github.com/maxbrunsfeld/counterfeiter/v6-6.13.0
Sep 15, 2026
Merged

openshift-merge-bot[bot] merged 2 commits into
masterfrom
dependabot/go_modules/github.com/maxbrunsfeld/counterfeiter/v6-6.13.0

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Sep 14, 2026

Copy link
Copy Markdown
Contributor

Bumps github.com/maxbrunsfeld/counterfeiter/v6 from 6.12.2 to 6.13.0.

Release notes

Sourced from github.com/maxbrunsfeld/counterfeiter/v6's releases.

v6.13.0

It's been a while since a release here had anything in it but dependency bumps. This one closes some of the oldest issues on the tracker: fakes can be generated into the interface's own package or into <package>_test, flags on the -generate line apply to every directive, loading is two to three times faster, and the README documents every flag.

counterfeiter now requires go 1.26. go 1.27 is out, and counterfeiter follows go's support policy, so 1.26 and 1.27 are the supported versions.

Where fakes can go

  • 🆕 A fake can be generated into the same package as its interface. Point -o at the package's own directory (-o ., or -o fake_foo_test.go so it is only compiled for tests) and the fake becomes a member of that package: no self-import, unqualified names, and the compile-time assertion stays, unexported interfaces included. Tests inside the package can use generated fakes without an import cycle. There is no new flag; detection is by directory, so fakes written anywhere else come out exactly as before. A stale same-package fake that no longer compiles does not stop you regenerating it. (#378, fixes #103, #121, #210, #262, and #68 from 2016)
  • 🆕 -test writes the fake into the external test package, <package>_test, as a _test.go file next to the tests that use it. It works for interfaces from other packages in your module, the standard library and third-party modules, so -test io.WriteCloser puts FakeWriteCloser in <package>_test, the package that tests <package>'s public API, and writes nothing anywhere else. @​nkovacs proposed and prototyped this in #135 in 2019. Thanks Nikola. (#383, fixes #135)
  • 🆕 The package clause of a fake follows whatever package already lives in the output directory, and is named after the directory only when there is nothing there yet. So fakes/ can hold package impl_fakes: add a doc.go declaring it and generate. Existing fakes packages are unaffected, their files already match the directory. (#384, fixes #249)
  • A fake of an unexported interface generated into its own package is unexported too: gadget gets fakeGadget, not FakeGadget. -fake-name is left alone. (#386)

Flags on the -generate line are defaults

  • 🆕 -o, -header, -q, -test and the new -fake-name-template given alongside -generate apply to every counterfeiter:generate directive in the package. A directive's own flags still win. -fake-name-template is a text/template over {{.TargetName}}, so -generate -o fake -fake-name-template '{{.TargetName}}' puts every fake in a fake package named after its interface, written once instead of -o and -fake-name on every line. This is @​matt-royal's design and fixture from #195, re-applied on the current tree. Thanks Matt. (#379, fixes #191)

⚡️ moar speed

  • Only the target package is type-checked from source now. Everything it imports is read from export data through the go build cache, instead of the whole dependency graph being type-checked on every run, stdlib included. On cloudfoundry/cli's actor/v7action (11 fakes) with a warm build cache:

    • one //go:generate line per fake: 4.7 seconds, was 11
    • the same package on a single -generate directive: 1.0 second, was 1.4, on a third of the CPU
    • a single fake on its own: 0.48 seconds, was 1.1
    • the repository benchmark: 130ms per uncached generate, was 600ms, allocating 7MB instead of 570MB

    The generated fakes are byte-for-byte identical across the fixture corpus. (#380, related #120, #181)

  • 🐛 Type errors in the target package that have nothing to do with the interface no longer stop generation: an import that can't be resolved in a sandboxed build, a broken file elsewhere in the package mid-refactor. A file that does not parse is still fatal. Otherwise generation fails only if the interface's own signatures use a type that could not be loaded, and the error names the method and quotes the load errors behind it. Based on @​navijation's #183. Thanks Navneeth. (#380, fixes #182)

Fixes

  • 🐛 Generic fakes with comparable, union or ~T constraints compile. The assertion lives in a blank generic function now, so any constraint works, and the packages constraints come from are imported instead of guessed from the type string. (#378, fixes #365)
  • 🐛 Reading Invocations() on a function fake while another goroutine calls it could deadlock. Interface fakes got this fix in v6.11.3; function fakes were missed. (#387, related #41, #44)
  • 🐛 Variadic arguments are recorded as a copy, like every other slice, so changing the slice after the call no longer changes what ArgsForCall and Invocations report. (#387)
  • 🐛 counterfeiter io.WriteCloser - prints to stdout, as the usage text says, instead of failing with "No such file/directory/package". (#383)
  • 🐛 A fake generated into a directory whose name differs from its package (go-foo holding package foo) compiles. (#383)
  • 🐛 generator.Cache, generator.CachedFileReader and Fake.Generate are safe to use from several goroutines, for anyone driving the generator as a library. The CLI never hit this. (#388)

📖 Docs

  • The README is rewritten so it's a bit more approachable for someone new to the tool: go get -tool and -generate as the recommended setup, a table of the defaults and how to change each, the common setups, the fake API, and the full -help output, which a test keeps in sync with the tool. The help text was wrong about -p and had no entry for -q. (#385, fixes #102)

🧹 Housekeeping

  • 🔁 CI actions updated to current majors by @​katsugtgz (#377)
  • ⬆️ dependency updates (gomega 1.43.0, x/tools 0.50.0, x/text 0.42.0)
  • the test suite runs in parallel and CI is about 40% faster on Linux (#388)

New Contributors

... (truncated)

Commits
  • 3f09632 Merge pull request #388 from maxbrunsfeld/faster-ci
  • 4f3f1ed run the race detector only where something is concurrent
  • 5db1011 make the caches safe to share and check the generator under concurrent use
  • fc28428 load each package once in the specs that only inspect the target
  • 80b1057 run the generator and integration specs in parallel
  • 9bd0b71 build the title caser per call so Generate can run concurrently
  • 305aa22 drop the install and build steps from the CI scripts
  • f26ad9d Merge pull request #387 from maxbrunsfeld/fake-race-audit
  • 7530f8b invoke counterfeiter with go run in the sql fixture like every other fixture
  • 77d1b5f record variadic arguments as a copy like other slices
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot Bot added dependencies Pull requests that update a dependency file go Pull requests that update Go code labels Sep 14, 2026
@coderabbitai

coderabbitai Bot commented Sep 14, 2026

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: 1ed4c373-a4ba-443c-ae30-f94d29cc85af

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@openshift-ci

openshift-ci Bot commented Sep 14, 2026

Copy link
Copy Markdown

Hi @dependabot[bot]. Thanks for your PR.

I'm waiting for a operator-framework member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@openshift-ci openshift-ci Bot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Sep 14, 2026

@rashmigottipati rashmigottipati left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/ok-to-test

@openshift-ci openshift-ci Bot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Sep 14, 2026
@perdasilva
perdasilva force-pushed the dependabot/go_modules/github.com/maxbrunsfeld/counterfeiter/v6-6.13.0 branch from a698a53 to 8d8de61 Compare September 15, 2026 07:33
@openshift-ci openshift-ci Bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Sep 15, 2026
dependabot Bot and others added 2 commits September 15, 2026 13:58
Bumps [github.com/maxbrunsfeld/counterfeiter/v6](https://github.com/maxbrunsfeld/counterfeiter) from 6.12.2 to 6.13.0.
- [Release notes](https://github.com/maxbrunsfeld/counterfeiter/releases)
- [Commits](maxbrunsfeld/counterfeiter@v6.12.2...v6.13.0)

---
updated-dependencies:
- dependency-name: github.com/maxbrunsfeld/counterfeiter/v6
  dependency-version: 6.13.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Per G. da Silva <pegoncal@redhat.com>
@perdasilva
perdasilva force-pushed the dependabot/go_modules/github.com/maxbrunsfeld/counterfeiter/v6-6.13.0 branch from 8d8de61 to c2442f3 Compare September 15, 2026 11:58
@openshift-ci openshift-ci Bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Sep 15, 2026
@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Sep 15, 2026
@openshift-ci

openshift-ci Bot commented Sep 15, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: perdasilva

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 15, 2026
@openshift-merge-bot
openshift-merge-bot Bot merged commit e618bbb into master Sep 15, 2026
19 checks passed
@dependabot
dependabot Bot deleted the dependabot/go_modules/github.com/maxbrunsfeld/counterfeiter/v6-6.13.0 branch September 15, 2026 12:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. dependencies Pull requests that update a dependency file go Pull requests that update Go code lgtm Indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants