mockery
« Back to VersTracker
Description:
Mock code autogenerator for Golang
Type: Formula  |  Latest Version: 3.6.1@0  |  Tracked Since: Nov 17, 2025
Links: Homepage  |  GitHub  |  Docs  |  formulae.brew.sh
Stars: 6,924  |  Forks: 449  |  Language: Go  |  Category: Developer tools
Tags: go golang testing mocking code-generation
Install: brew install mockery
About:
Mockery is a Go library that automatically generates mock implementations of Go interfaces. It simplifies unit testing by allowing developers to create mock objects that simulate the behavior of real dependencies, enabling isolated and controlled testing environments. Its primary value lies in reducing boilerplate code and improving test reliability.
Key Features:
  • Generates mock implementations for Go interfaces
  • Supports configuration via comments and configuration files
  • Can generate mocks for entire packages recursively
  • Integrates with the Go `test` command and popular testing frameworks
  • Provides version management for generated mocks
Use Cases:
  • Unit testing Go applications by mocking external dependencies
  • Test-driven development (TDD) workflows in Go projects
Alternatives:
  • testify/mock – Part of the testify suite; more manual, less code generation.
  • golang/mock – Official Go mock generator; uses interface-based generation like mockery.
Version History
Detected Version Rev Change Commit
Dec 26, 2025 5:43pm 3.6.1 0 VERSION_BUMP 0b776cc7
Nov 17, 2025 5:20pm 0 VERSION_BUMP 8fd6b04e
Oct 10, 2025 3:12pm 0 VERSION_BUMP 20bb3a23
Sep 15, 2025 11:40pm 0 VERSION_BUMP e9e9e547
Jan 14, 2025 8:02am 0 VERSION_BUMP d40b5c68
Dec 30, 2024 11:36pm 0 VERSION_BUMP 5b6cc609
Dec 30, 2024 11:02pm 0 VERSION_BUMP c1de1b74
Dec 4, 2024 5:15pm 0 VERSION_BUMP c75217f4
Nov 27, 2024 2:54am 0 VERSION_BUMP bbe87bba
Nov 19, 2024 6:56am 0 VERSION_BUMP a050b565
Nov 14, 2024 8:07pm 0 VERSION_BUMP af98f561
Oct 2, 2024 5:14pm 0 VERSION_BUMP 6fe10a6a
Oct 2, 2024 3:53pm 0 VERSION_BUMP 8de925c2
Sep 17, 2024 8:29am 0 VERSION_BUMP b6a3796a
Sep 17, 2024 6:49am 0 VERSION_BUMP c1050570