github.com/golangCi/golangCi-lint@v1.10.1/test/testdata/golint.go (about)

     1  // args: -Egolint
     2  package testdata
     3  
     4  var Go_lint string // ERROR "don't use underscores in Go names; var Go_lint should be GoLint"
     5  
     6  func ExportedFuncWithNoComment() {
     7  }
     8  
     9  var ExportedVarWithNoComment string
    10  
    11  type ExportedStructWithNoComment struct{}
    12  
    13  type ExportedInterfaceWithNoComment interface{}
    14  
    15  // Bad comment
    16  func ExportedFuncWithBadComment() {}
    17  
    18  type GolintTest struct{}
    19  
    20  func (receiver1 GolintTest) A() {}
    21  
    22  func (receiver2 GolintTest) B() {} // ERROR "receiver name receiver2 should be consistent with previous receiver name receiver1 for GolintTest"