Preparing report...

Report for github.com/adamluzsi/testcase

A+    Excellent!    Found 28 issues across 131 files

Tweet

gofmt100%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command

No problems detected. Good job!


go_vet100%

go vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.

No problems detected. Good job!


gocyclo100%

Gocyclo calculates cyclomatic complexities of functions in Go source code. The cyclomatic complexity of a function is calculated according to the following rules: 1 is the base complexity of a function +1 for each 'if', 'for', 'case', '&&' or '||' Go Report Card warns on functions with cyclomatic complexity > 15.

No problems detected. Good job!


golint79%

Golint is a linter for Go source code.

    • testcase/docs/examples/role/main.go
    • Line 10: warning: exported type Entity should have comment or be unexported (golint)
    • Line 17: warning: exported type Consumer should have comment or be unexported (golint)
    • Line 21: warning: comment on exported type Storage should be of the form "Storage ..." (with optional leading article) (golint)
    • Line 27: warning: exported method Consumer.A should have comment or be unexported (golint)
    • testcase/contracts/CustomTB.go
    • Line 13: warning: exported type CustomTB should have comment or be unexported (golint)
    • Line 17: warning: exported method CustomTB.Test should have comment or be unexported (golint)
    • Line 19: warning: exported method CustomTB.Benchmark should have comment or be unexported (golint)
    • Line 21: warning: exported method CustomTB.Spec should have comment or be unexported (golint)
    • testcase/random/crypto.go
    • Line 8: warning: exported type CryptoSeed should have comment or be unexported (golint)
    • Line 10: warning: exported method CryptoSeed.Uint64 should have comment or be unexported (golint)
    • testcase/internal/RecorderTB.go
    • Line 9: warning: exported type RecorderTB should have comment or be unexported (golint)
    • Line 50: warning: exported method RecorderTB.Forward should have comment or be unexported (golint)
    • Line 59: warning: exported method RecorderTB.CleanupNow should have comment or be unexported (golint)
    • Line 79: warning: exported method RecorderTB.Run should have comment or be unexported (golint)
    • Line 102: warning: exported method RecorderTB.Cleanup should have comment or be unexported (golint)
    • Line 109: warning: exported method RecorderTB.Helper should have comment or be unexported (golint)
    • Line 115: warning: exported method RecorderTB.Log should have comment or be unexported (golint)
    • Line 121: warning: exported method RecorderTB.Logf should have comment or be unexported (golint)
    • Line 131: warning: exported method RecorderTB.Fail should have comment or be unexported (golint)
    • Line 143: warning: exported method RecorderTB.FailNow should have comment or be unexported (golint)
    • Line 158: warning: exported method RecorderTB.Errorf should have comment or be unexported (golint)
    • Line 165: warning: exported method RecorderTB.Fatal should have comment or be unexported (golint)
    • Line 173: warning: exported method RecorderTB.Fatalf should have comment or be unexported (golint)
    • Line 181: warning: exported method RecorderTB.Failed should have comment or be unexported (golint)
    • testcase/T.go
    • Line 84: warning: exported method T.Cleanup should have comment or be unexported (golint)
    • Line 114: warning: exported method T.HasTag should have comment or be unexported (golint)
    • testcase/ordering.go
    • Line 33: warning: exported const OrderingAsDefined should have comment (or a comment on this block) or be unexported (golint)
    • testcase/internal/example/storages/Storage.go
    • Line 8: warning: comment on exported function New should be of the form "New ..." (golint)
    • Line 14: warning: exported type Storage should have comment or be unexported (golint)
    • Line 18: warning: exported method Storage.Close should have comment or be unexported (golint)
    • Line 22: warning: exported method Storage.BeginTx should have comment or be unexported (golint)
    • Line 26: warning: exported method Storage.CommitTx should have comment or be unexported (golint)
    • Line 30: warning: exported method Storage.RollbackTx should have comment or be unexported (golint)
    • testcase/internal/toggles.go
    • Line 7: warning: exported function SetupCacheFlush should have comment or be unexported (golint)
    • Line 14: warning: exported function RegisterCacheFlush should have comment or be unexported (golint)
    • Line 19: warning: exported function CacheFlush should have comment or be unexported (golint)
    • testcase/fixtures/Option.go
    • Line 8: warning: exported type Options should have comment or be unexported (golint)
    • Line 10: warning: exported method Options.Testing should have comment or be unexported (golint)
    • Line 12: warning: exported type Option should have comment or be unexported (golint)
    • Line 18: warning: exported function NewConfig should have comment or be unexported (golint)
    • Line 26: warning: exported type Config should have comment or be unexported (golint)
    • Line 30: warning: exported method Config.GetSkipTags should have comment or be unexported (golint)
    • Line 39: warning: exported method Config.CanPopulateStructField should have comment or be unexported (golint)
    • testcase/internal/StubTB.go
    • Line 8: warning: exported type StubTB should have comment or be unexported (golint)
    • Line 23: warning: exported method StubTB.Finish should have comment or be unexported (golint)
    • Line 27: warning: exported method StubTB.Cleanup should have comment or be unexported (golint)
    • Line 35: warning: exported method StubTB.Errorf should have comment or be unexported (golint)
    • Line 39: warning: exported method StubTB.Fail should have comment or be unexported (golint)
    • Line 43: warning: exported method StubTB.FailNow should have comment or be unexported (golint)
    • Line 52: warning: exported method StubTB.Failed should have comment or be unexported (golint)
    • Line 56: warning: exported method StubTB.Fatal should have comment or be unexported (golint)
    • Line 60: warning: exported method StubTB.Fatalf should have comment or be unexported (golint)
    • Line 64: warning: exported method StubTB.Helper should have comment or be unexported (golint)
    • Line 66: warning: exported method StubTB.Log should have comment or be unexported (golint)
    • Line 68: warning: exported method StubTB.Logf should have comment or be unexported (golint)
    • Line 70: warning: exported method StubTB.Name should have comment or be unexported (golint)
    • Line 74: warning: exported method StubTB.Skip should have comment or be unexported (golint)
    • Line 78: warning: exported method StubTB.SkipNow should have comment or be unexported (golint)
    • Line 83: warning: exported method StubTB.Skipf should have comment or be unexported (golint)
    • Line 87: warning: exported method StubTB.Skipped should have comment or be unexported (golint)
    • Line 91: warning: exported method StubTB.TempDir should have comment or be unexported (golint)
    • testcase/internal/mocks/new.go
    • Line 1: warning: package comment should be of the form "Package mocks ..." (golint)
    • Line 13: warning: exported function New should have comment or be unexported (golint)
    • Line 24: warning: exported function NewMock should have comment or be unexported (golint)
    • Line 29: warning: comment on exported function NewWithDefaults should be of the form "NewWithDefaults ..." (golint)
    • Line 34: warning: exported function SetupDefaultBehavior should have comment or be unexported (golint)
    • testcase/random/random.go
    • Line 10: warning: exported function New should have comment or be unexported (golint)
    • Line 56: warning: exported method Random.ElementFromSlice should have comment or be unexported (golint)
    • Line 62: warning: exported method Random.KeyFromMap should have comment or be unexported (golint)
    • Line 68: warning: exported method Random.Bool should have comment or be unexported (golint)
    • Line 76: warning: exported method Random.StringN should have comment or be unexported (golint)
    • Line 81: warning: exported method Random.StringNWithCharset should have comment or be unexported (golint)
    • Line 102: warning: exported method Random.Time should have comment or be unexported (golint)
    • testcase/docs/examples/DependsOnFailable.go
    • Line 3: warning: exported type DependsOnFailable should have comment or be unexported (golint)
    • Line 7: warning: exported method DependsOnFailable.Run should have comment or be unexported (golint)
    • Line 11: warning: exported type Failable should have comment or be unexported (golint)
    • testcase/docs/examples/MyStruct.go
    • Line 8: warning: exported type MyStruct should have comment or be unexported (golint)
    • Line 10: warning: exported method MyStruct.Say should have comment or be unexported (golint)
    • Line 14: warning: exported method MyStruct.Foo should have comment or be unexported (golint)
    • Line 18: warning: exported method MyStruct.Bar should have comment or be unexported (golint)
    • Line 22: warning: exported method MyStruct.Baz should have comment or be unexported (golint)
    • Line 26: warning: exported method MyStruct.Shrug should have comment or be unexported (golint)
    • testcase/fixtures/Fixture.go
    • Line 13: warning: exported type IFactory should have comment or be unexported (golint)
    • Line 18: warning: exported function NewFactory should have comment or be unexported (golint)
    • Line 22: warning: exported type Factory should have comment or be unexported (golint)
    • Line 37: warning: exported type FactoryFunc should have comment or be unexported (golint)
    • Line 48: warning: context.Context should be the first parameter of a function (golint)
    • Line 48: warning: exported method Factory.Create should have comment or be unexported (golint)
    • Line 68: warning: exported method Factory.Context should have comment or be unexported (golint)
    • Line 76: warning: exported method Factory.RegisterType should have comment or be unexported (golint)
    • Line 103: warning: context.Context should be the first parameter of a function (golint)
    • Line 107: warning: context.Context should be the first parameter of a function (golint)
    • Line 111: warning: context.Context should be the first parameter of a function (golint)
    • Line 115: warning: context.Context should be the first parameter of a function (golint)
    • Line 119: warning: context.Context should be the first parameter of a function (golint)
    • Line 123: warning: context.Context should be the first parameter of a function (golint)
    • Line 127: warning: context.Context should be the first parameter of a function (golint)
    • Line 131: warning: context.Context should be the first parameter of a function (golint)
    • Line 135: warning: context.Context should be the first parameter of a function (golint)
    • Line 139: warning: context.Context should be the first parameter of a function (golint)
    • Line 143: warning: context.Context should be the first parameter of a function (golint)
    • Line 147: warning: context.Context should be the first parameter of a function (golint)
    • Line 151: warning: context.Context should be the first parameter of a function (golint)
    • Line 155: warning: context.Context should be the first parameter of a function (golint)
    • Line 159: warning: context.Context should be the first parameter of a function (golint)
    • Line 163: warning: context.Context should be the first parameter of a function (golint)
    • Line 180: warning: context.Context should be the first parameter of a function (golint)
    • Line 191: warning: context.Context should be the first parameter of a function (golint)
    • Line 199: warning: context.Context should be the first parameter of a function (golint)
    • Line 213: warning: context.Context should be the first parameter of a function (golint)
    • Line 229: warning: context.Context should be the first parameter of a function (golint)
    • Line 242: warning: context.Context should be the first parameter of a function (golint)
    • testcase/Retry.go
    • Line 17: warning: exported type RetryStrategy should have comment or be unexported (golint)
    • Line 24: warning: exported type RetryStrategyFunc should have comment or be unexported (golint)
    • Line 26: warning: exported method RetryStrategyFunc.While should have comment or be unexported (golint)
    • Line 58: warning: exported function RetryCount should have comment or be unexported (golint)
    • testcase/opts.go
    • Line 47: warning: exported function SkipBenchmark should have comment or be unexported (golint)
    • Line 76: warning: exported type SpecOption should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign99%

IneffAssign detects ineffectual assignments in Go code.


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!