github.com/stretchr/testify
v1.12.1
#85 most downloaded on Go modules
stretchr/testify
What this package is like to depend on
Last release 3 days ago
20 Aug 2026
Release timing varies
gaps range from 8 days to 3 months
Some releases are documented
notes for 9 of 30 stable releases
Nothing withdrawn
no release was ever pulled
14 years old
951 releases · first in 2012
52 releases in the last 12 months
see the full history below
Release timeline
951 releases · Oct 2012 to Aug 2026Releases
latest 60 of 951-
v1.12.2-0.20260820143810-c627960a732320 Aug 2026 pre-releaseNothing published for this version
-
v1.12.117 Aug 2026Release notes
Open source →This is the first release which has the minimum dependencies practical in testify v1. The last remaining dependencies are github.com/stretchr/objx which itself has no dependencies, and go.yaml.in/yaml/v3. Removing objx would require v2, it cannot be vendored. Removing YAML would require vendoring the yaml library, which would do more harm than good. It's better to become aware of vulnerabilities in the official yaml package than to attempt to maintain our own.
What's Changed
- Change yaml library to
go.yaml.in/yaml/v3by @harryzcy in #1935 - change yaml library to go.yaml.in/yaml/v3 by @boekkooi-impossiblecloud in #1772
New Contributors
- @harryzcy made their first contribution in #1935
- @boekkooi-impossiblecloud made their first contribution in #1772
Full Changelog: v1.12.0...v1.12.1
What's Changed
- Change yaml library to
go.yaml.in/yaml/v3by @harryzcy in #1935 - change yaml library to go.yaml.in/yaml/v3 by @boekkooi-impossiblecloud in #1772
New Contributors
- @harryzcy made their first contribution in #1935
- @boekkooi-impossiblecloud made their first contribution in #1772
Full Changelog: v1.12.0...v1.12.1
- Change yaml library to
-
v1.12.1-0.20260817082405-959dbdacf15317 Aug 2026 pre-releaseNothing published for this version
-
v1.12.010 Jun 2026Release notes
Open source →What's Changed
Functional Changes
Fixes
- mock: avoid panic when expected type is nil in Arguments.Diff by @mutaiib in #1775
- mock: revert to pre-v1.11.0 argument matching behavior for mutating stringers by @brackendawson in #1786
- suite: validate method signatures and continue execution for valid tests by @vyas-git in #1665
- assert.PanicsWithError: report error message by @olivergondza in #1400
- assert: IsIncreasing et al can return false w/out failing by @brackendawson in #1787
- add type to error message of assert.Same by @egawata in #1792
- mock.AssertExpectationsForObjects fix panic with wrong testObject type. by @brackendawson in #1795
- assert: truncate very long objects in test failure messages by @brackendawson in #1646
- assert: fix NotSubset error messages using %#v instead of %q (fixes #1800) by @nghiack7 in #1888
- suite: prevent panic when SetupTest skips with HandleStats by @blackwell-systems in #1877
Documentation, Build & CI
- CI: test also with Go 1.23 by @dolmen in #1783
- Vendor unmaintained github.com/pmezard/go-difflib by @brackendawson in #1708
- Promote ccoVeille to maintainer by @brackendawson in #1784
- build(deps): bump actions/setup-go from 5 to 6 by @dependabot[bot] in #1790
- assert.YAMLEq: Document mutlidoc behavior by @brackendawson in #1791
- _codegen: copy dependency github.com/ernesto-jimenez/gogen/imports by @dolmen in #1782
- doc: remove ineffective inline code blocks by @brackendawson in #1714
- Tag generated assertions as non-generated in new .gitattributes by @ubunatic in #1815
- chore: vendor go-spew from https://github.com/davecgh/go-spew by @ccoVeille in #1827
- require: fix godoc generation for assertions returning a bool by @Baxromumarov in #1850
- docs(require): correct example usage to use assert.CollectT (require.CollectT does not exist) by @a2not in #1821
- docs: Fix EventuallyWithTf documentation with proper placement of formatting arguments by @a2not in #1842
- EMERITUS.md: add @tylerb by @dolmen in #1812
- CI: test also with Go 1.24 by @alexandear in #1856
- deps: bump objx to v0.5.3 and remove dependency cycle issue by @ccoVeille in #1823
- CI: upgrade GitHub Actions and pin hashes by @SuperQ in #1883
- CI: add _readme-gofmt tool to reformat Go code in README by @dolmen in #1889
- CI: add check of GitHub Action pinned hashes against tag by @dolmen in #1885
- _codegen: modernize by @dolmen in #1890
- build(deps): bump actions/checkout from 6.0.2 to 6.0.3 by @dependabot[bot] in #1906
- mock: Mock.Return does not exist anymore by @Kentzo in #1905
New Contributors
- @mutaiib made their first contribution in #1775
- @vyas-git made their first contribution in #1665
- @olivergondza made their first contribution in #1400
- @egawata made their first contribution in #1792
- @ubunatic made their first contribution in #1815
- @Baxromumarov made their first contribution in #1850
- @a2not made their first contribution in #1821
- @nghiack7 made their first contribution in #1888
- @blackwell-systems made their first contribution in #1877
- @Kentzo made their first contribution in #1905
Full Changelog: v1.11.0...v1.12.0
What's Changed
- mock: avoid panic when expected type is nil in Arguments.Diff by @mutaiib in #1775
- CI: test also with Go 1.23 by @dolmen in #1783
- mock: revert to pre-v1.11.0 argument matching behavior for mutating stringers by @brackendawson in #1786
- suite: validate method signatures and continue execution for valid tests by @vyas-git in #1665
- Vendor unmaintained github.com/pmezard/go-difflib by @brackendawson in #1708
- Promote ccoVeille to maintainer by @brackendawson in #1784
- build(deps): bump actions/setup-go from 5 to 6 by @dependabot[bot] in #1790
- assert.PanicsWithError: report error message by @olivergondza in #1400
- assert: IsIncreasing et al can return false w/out failing by @brackendawson in #1787
- add type to error message of assert.Same by @egawata in #1792
- assert.YAMLEq: Document mutlidoc behavior by @brackendawson in #1791
- mock.AssertExpectationsForObjects fix panic with wrong testObject type. by @brackendawson in #1795
- _codegen: copy dependency github.com/ernesto-jimenez/gogen/imports by @dolmen in #1782
- assert: truncate very long objects in test failure messages by @brackendawson in #1646
- doc: remove ineffective inline code blocks by @brackendawson in #1714
- Tag generated assertions as non-generated in new .gitattributes by @ubunatic in #1815
- chore: vendor go-spew from https://github.com/davecgh/go-spew by @ccoVeille in #1827
- require: fix godoc generation for assertions returning a bool by @Baxromumarov in #1850
- docs(require): correct example usage to use assert.CollectT (require.CollectT does not exist) by @a2not in #1821
- docs: Fix EventuallyWithTf documentation with proper placement of formatting arguments by @a2not in #1842
- EMERITUS.md: add @tylerb by @dolmen in #1812
- CI: test also with Go 1.24 by @alexandear in #1856
- deps: bump objx to v0.5.3 and remove dependency cycle issue by @ccoVeille in #1823
- CI: upgrade GitHub Actions and pin hashes by @SuperQ in #1883
- assert: fix NotSubset error messages using %#v instead of %q (fixes #1800) by @nghiack7 in #1888
- suite: prevent panic when SetupTest skips with HandleStats by @blackwell-systems in #1877
- CI: add _readme-gofmt tool to reformat Go code in README by @dolmen in #1889
- CI: add check of GitHub Action pinned hashes against tag by @dolmen in #1885
- _codegen: modernize by @dolmen in #1890
- assert: make *AssertionFunc types just aliases by @dolmen in #1563
- build(deps): bump actions/checkout from 6.0.2 to 6.0.3 by @dependabot[bot] in #1906
- mock: Mock.Return does not exist anymore by @Kentzo in #1905
New Contributors
- @mutaiib made their first contribution in #1775
- @vyas-git made their first contribution in #1665
- @olivergondza made their first contribution in #1400
- @egawata made their first contribution in #1792
- @ubunatic made their first contribution in #1815
- @Baxromumarov made their first contribution in #1850
- @a2not made their first contribution in #1821
- @nghiack7 made their first contribution in #1888
- @blackwell-systems made their first contribution in #1877
- @Kentzo made their first contribution in #1905
Full Changelog: v1.11.0...v1.12.0
-
v1.11.127 Aug 2025Release notes
Open source →This release fixes #1785 introduced in v1.11.0 where expected argument values implementing the stringer interface (
String() string) with a method which mutates their value, when passed to mock.Mock.On (m.On("Method", <expected>).Return()) or actual argument values passed to mock.Mock.Called may no longer match one another where they previously did match. The behaviour prior to v1.11.0 where the stringer is always called is restored. Future testify releases may not call the stringer method at all in this case.What's Changed
- Backport #1786 to release/1.11: mock: revert to pre-v1.11.0 argument matching behavior for mutating stringers by @brackendawson in #1788
Full Changelog: v1.11.0...v1.11.1
-
v1.11.1-0.20260610141043-001eb7946baf10 Jun 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20260515015452-12f8b5612e1215 May 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20260513134753-dc20f419863a13 May 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20260511152800-37a3cb7cc08411 May 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20260507153116-c920f8006d6507 May 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20260506081252-d75b7070920f06 May 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20260304064832-5f80e4aef7be04 Mar 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20260225135613-b13d7e38ac6125 Feb 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20260223190237-c7007d3defa023 Feb 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20260217151418-101072d18a7d17 Feb 2026 pre-releaseNothing published for this version
-
v1.11.1-0.20251128102321-65697cefca1d28 Nov 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20251022131221-429ee0b8f4ef22 Oct 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250919115354-feb1324bc3d019 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250919114251-49bcd2ad672319 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250916131232-6c30310a8d0c16 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250915125144-a0ac157f0b1f15 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250913203643-5fa984a7595b13 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250912062812-b9167dae658012 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250911163653-f03d0371524211 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250910065339-b5a0821dcb5110 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250909071446-cbd8483e626109 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250909061828-5afd74fb37ea09 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250901062747-a87733af711101 Sep 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250831184432-38d9e83f5afa31 Aug 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250829151237-ce48cb33eae029 Aug 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250829091646-e8daaaca9cd529 Aug 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250827103133-c952903e9f7327 Aug 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250825141246-f4f5960503ab25 Aug 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250825140554-af161709418f25 Aug 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250825121340-580d8071120025 Aug 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250818193004-e581b36d7b3618 Aug 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250818160815-b9a23f4b6a8818 Aug 2025 pre-releaseNothing published for this version
-
v1.11.1-0.20250818160815-8976267da7c418 Aug 2025 pre-releaseNothing published for this version
-
v1.11.017 Aug 2025Release notes
Open source →What's Changed
Functional Changes
v1.11.0 Includes a number of performance improvements.
- Call stack perf change for CallerInfo by @mikeauclair in #1614
- Lazily render mock diff output on successful match by @mikeauclair in #1615
- assert: check early in Eventually, EventuallyWithT, and Never by @cszczepaniak in #1427
- assert: add IsNotType by @bartventer in #1730
- assert.JSONEq: shortcut if same strings by @dolmen in #1754
- assert.YAMLEq: shortcut if same strings by @dolmen in #1755
- assert: faster and simpler isEmpty using reflect.Value.IsZero by @dolmen in #1761
- suite: faster methods filtering (internal refactor) by @dolmen in #1758
Fixes
- assert.ErrorAs: log target type by @craig65535 in #1345
- Fix failure message formatting for Positive and Negative asserts in #1062
- Improve ErrorIs message when error is nil but an error was expected by @tsioftas in #1681
- fix Subset/NotSubset when calling with mixed input types by @siliconbrain in #1729
- Improve ErrorAs failure message when error is nil by @ccoVeille in #1734
- mock.AssertNumberOfCalls: improve error msg by @3scalation in #1743
Documentation, Build & CI
- docs: Fix typo in README by @alexandear in #1688
- Replace deprecated io/ioutil with io and os by @alexandear in #1684
- Document consequences of calling t.FailNow() by @greg0ire in #1710
- chore: update docs for Unset #1621 by @techfg in #1709
- README: apply gofmt to examples by @alexandear in #1687
- refactor: use %q and %T to simplify fmt.Sprintf by @alexandear in #1674
- Propose Christophe Colombier (ccoVeille) as approver by @brackendawson in #1716
- Update documentation for the Error function in assert or require package by @architagr in #1675
- assert: remove deprecated build constraints by @alexandear in #1671
- assert: apply gofumpt to internal test suite by @ccoVeille in #1739
- CI: fix shebang in .ci.*.sh scripts by @dolmen in #1746
- assert,require: enable parallel testing on (almost) all top tests by @dolmen in #1747
- suite.Passed: add one more status test report by @Ararsa-Derese in #1706
- Add Helper() method in internal mocks and assert.CollectT by @dolmen in #1423
- assert.Same/NotSame: improve usage of Sprintf by @ccoVeille in #1742
- mock: enable parallel testing on internal testsuite by @dolmen in #1756
- suite: cleanup use of 'testing' internals at runtime by @dolmen in #1751
- assert: check test failure message for Empty and NotEmpty by @ccoVeille in #1745
- deps: fix dependency cycle with objx (again) by @dolmen in #1567
- assert.Empty: comprehensive doc of "Empty"-ness rules by @dolmen in #1753
- doc: improve godoc of top level 'testify' package by @dolmen in #1760
- assert.ErrorAs: simplify retrieving the type name by @ccoVeille in #1740
- assert.EqualValues: improve test coverage to 100% by @dolmen in #1763
- suite.Run: simplify running of Setup/TeardownSuite by @renzoarreaza in #1769
- assert.CallerInfo: micro optimization by using LastIndexByte by @dolmen in #1767
- assert.CallerInfo: micro cleanup by @dolmen in #1768
- assert: refactor TestFileExists and TestDirExists tests to enable parallel testing by @dolmen in #1766
- suite.Run: refactor handling of stats for improved readability by @dolmen in #1764
- tests: improve captureTestingT helper by @ccoVeille in #1741
- build(deps): bump actions/checkout from 4 to 5 by @dependabot[bot] in #1778
New Contributors
- @greg0ire made their first contribution in #1710
- @techfg made their first contribution in #1709
- @mikeauclair made their first contribution in #1614
- @cszczepaniak made their first contribution in #1427
- @architagr made their first contribution in #1675
- @tsioftas made their first contribution in #1681
- @siliconbrain made their first contribution in #1729
- @bartventer made their first contribution in #1730
- @Ararsa-Derese made their first contribution in #1706
- @renzoarreaza made their first contribution in #1769
- @3scalation made their first contribution in #1743
Full Changelog: v1.10.0...v1.11.0
-
v1.10.1-0.20250818193004-e581b36d7b3618 Aug 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250817155751-b7801fbf5cd517 Aug 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250701074529-a53be35c3b0c01 Jul 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250630161813-aafb604176db30 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250630161345-929a2126c27030 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250630160624-87101a6e4a5830 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250620081022-5c949551ee9620 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250619081800-b50b016f525919 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250616142133-7c2bbf9ebc9416 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250604180040-7127b609990204 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250604111530-26b02e2f383f04 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250603130406-7bcd66c6d68403 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250603095319-7a1b408b7ce103 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250602221108-c519b7942b8602 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250602150025-5d95b18ab53602 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250601213923-553e822bab7001 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250601213922-250eaa5e06e401 Jun 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250531124810-a5d5c3395e0731 May 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250530152203-0ff4bb43de0b30 May 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250530140810-4f71159ca8c630 May 2025 pre-releaseNothing published for this version
-
v1.10.1-0.20250527214248-3c1541a3b40227 May 2025 pre-releaseNothing published for this version