File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 4
4
package db // it's not db_test, because this file is for testing the private type halfCommitter
5
5
6
6
import (
7
- "fmt "
7
+ "errors "
8
8
"testing"
9
9
10
10
"github.com/stretchr/testify/assert"
@@ -80,7 +80,7 @@ func Test_halfCommitter(t *testing.T) {
80
80
testWithCommitter (mockCommitter , func (committer Committer ) error {
81
81
defer committer .Close ()
82
82
if true {
83
- return fmt . Errorf ("error" )
83
+ return errors . New ("error" )
84
84
}
85
85
return committer .Commit ()
86
86
})
@@ -94,7 +94,7 @@ func Test_halfCommitter(t *testing.T) {
94
94
testWithCommitter (mockCommitter , func (committer Committer ) error {
95
95
committer .Close ()
96
96
committer .Commit ()
97
- return fmt . Errorf ("error" )
97
+ return errors . New ("error" )
98
98
})
99
99
100
100
mockCommitter .Assert (t )
You can’t perform that action at this time.
0 commit comments