If one of the methods has parameters which are functions that also have parameters that the generated interface file misses those imports
file bar.go
package interfaces
type Bar struct{}
func (*Bar) Foo(func(bar *Bar)) {}
file bar_interface.go
// Code generated by interfacer; DO NOT EDIT
package luts3
import (
)
// FooBar is an interface generated for "interfaces.Bar".
type FooBar interface {
Foo(func(*interfaces.Bar))
}
It's missing the import for function parameter bar for the method parameter func(*Bar).
Instead it should be
// Code generated by interfacer; DO NOT EDIT
package luts3
import (
"/path/interfaces"
)
// FooBar is an interface generated for "interfaces.Bar".
type FooBar interface {
Foo(func(*interfaces.Bar))
}
If one of the methods has parameters which are functions that also have parameters that the generated interface file misses those imports
file bar.go
file bar_interface.go
It's missing the import for function parameter
barfor the method parameterfunc(*Bar).Instead it should be