Skip to content

Commit

Permalink
Undo deprecation of Controller.Finish()
Browse files Browse the repository at this point in the history
We're about to release a new version, and we need to reach some more
consensus on this decision. Undoing this deprecation for the time
being for v0.3.0 release.

Ref: #84.
  • Loading branch information
sywhang committed Sep 15, 2023
1 parent dad3840 commit 1f4e3c2
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions gomock/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -236,9 +236,6 @@ func (ctrl *Controller) Call(receiver any, method string, args ...any) []any {

// Finish checks to see if all the methods that were expected to be called were called.
// It is not idempotent and therefore can only be invoked once.
//
// Deprecated: Calling this function in test methods is not required starting from Go 1.14.
// It will be called automatically from a self registered [testing.T.Cleanup] function.
func (ctrl *Controller) Finish() {
// If we're currently panicking, probably because this is a deferred call.
// This must be recovered in the deferred function.
Expand Down

0 comments on commit 1f4e3c2

Please sign in to comment.