Skip to content

skipping test defined methods, or add -exclude flat #39

@Liooo

Description

@Liooo

I'm trying to generate an interface for a struct in an external library, but they define additional methods in test file, and I don't want the generated interface to have those.

e.g.

// --- external.go ---
package external

type TheirStruct struct{}

// we want this
func (t TheirStruct) SomeMethod() {
} 

// --- external_test.go ---
package external

 // but we do not want this
func (t TheirStruct) SomeTestMethod() {
}

Would be great if this tool automatically skips test file defined methods, or have an -exclude flag that takes names of methods to be skipped.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions