Skip to content

Commit 93699e7

Browse files
committed
Add stdlib import
1 parent 1f37361 commit 93699e7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

pkg/golinters/iface/testdata/unused.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,21 @@
22
//golangcitest:config_path testdata/unused.yml
33
package testdata
44

5+
import "context"
6+
57
type User struct {
68
ID string
79
Name string
810
}
911

1012
type UserRepository interface { // want "interface UserRepository is declared but not used within the package"
11-
UserOf(id string) (*User, error)
13+
UserOf(ctx context.Context, id string) (*User, error)
1214
}
1315

1416
type UserRepositorySQL struct {
1517
}
1618

17-
func (r *UserRepositorySQL) UserOf(id string) (*User, error) {
19+
func (r *UserRepositorySQL) UserOf(ctx context.Context, id string) (*User, error) {
1820
return nil, nil
1921
}
2022

0 commit comments

Comments
 (0)