mirror of
https://github.com/mgechev/revive.git
synced 2025-11-23 22:04:49 +02:00
test: remove useless comments (#1173)
This commit is contained in:
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// Atomic rule.
|
||||
func TestAtomic(t *testing.T) {
|
||||
testRule(t, "atomic", &rule.AtomicRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// BoolLiteral rule.
|
||||
func TestBoolLiteral(t *testing.T) {
|
||||
testRule(t, "bool_literal_in_expr", &rule.BoolLiteralRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestCallToGC test call-to-gc rule
|
||||
func TestCallToGC(t *testing.T) {
|
||||
testRule(t, "call_to_gc", &rule.CallToGCRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestConfusingNaming rule.
|
||||
func TestConfusingNaming(t *testing.T) {
|
||||
testRule(t, "confusing_naming1", &rule.ConfusingNamingRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// ConstantLogicalExpr rule.
|
||||
func TestConstantLogicalExpr(t *testing.T) {
|
||||
testRule(t, "constant_logical_expr", &rule.ConstantLogicalExprRule{})
|
||||
}
|
||||
|
||||
@@ -7,7 +7,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// Defer rule.
|
||||
func TestDefer(t *testing.T) {
|
||||
testRule(t, "defer", &rule.DeferRule{})
|
||||
}
|
||||
|
||||
@@ -8,7 +8,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestEarlyReturn tests early-return rule.
|
||||
func TestEarlyReturn(t *testing.T) {
|
||||
testRule(t, "early_return", &rule.EarlyReturnRule{})
|
||||
testRule(t, "early_return_scope", &rule.EarlyReturnRule{}, &lint.RuleConfig{Arguments: []any{ifelse.PreserveScope}})
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestEmptyBlock rule.
|
||||
func TestEmptyBlock(t *testing.T) {
|
||||
testRule(t, "empty_block", &rule.EmptyBlockRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestEmptyLines rule.
|
||||
func TestEmptyLines(t *testing.T) {
|
||||
testRule(t, "empty_lines", &rule.EmptyLinesRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// IdenticalBranches rule.
|
||||
func TestIdenticalBranches(t *testing.T) {
|
||||
testRule(t, "identical_branches", &rule.IdenticalBranchesRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestIfReturn rule.
|
||||
func TestIfReturn(t *testing.T) {
|
||||
testRule(t, "if_return", &rule.IfReturnRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestModifiesParam rule.
|
||||
func TestModifiesParam(t *testing.T) {
|
||||
testRule(t, "modifies_param", &rule.ModifiesParamRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// Tests RedefinesBuiltinID rule.
|
||||
func TestRedefinesBuiltinID(t *testing.T) {
|
||||
testRule(t, "redefines_builtin_id", &rule.RedefinesBuiltinIDRule{})
|
||||
}
|
||||
|
||||
@@ -5,7 +5,6 @@ import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
// TestRedundantImportAlias rule.
|
||||
func TestRedundantImportAlias(t *testing.T) {
|
||||
testRule(t, "redundant_import_alias", &rule.RedundantImportAlias{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// String-of-int rule.
|
||||
func TestStringOfInt(t *testing.T) {
|
||||
testRule(t, "string_of_int", &rule.StringOfIntRule{})
|
||||
}
|
||||
|
||||
@@ -7,7 +7,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestStructTag tests struct-tag rule
|
||||
func TestStructTag(t *testing.T) {
|
||||
testRule(t, "struct_tag", &rule.StructTagRule{})
|
||||
}
|
||||
|
||||
@@ -8,7 +8,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestSuperfluousElse rule.
|
||||
func TestSuperfluousElse(t *testing.T) {
|
||||
testRule(t, "superfluous_else", &rule.SuperfluousElseRule{})
|
||||
testRule(t, "superfluous_else_scope", &rule.SuperfluousElseRule{}, &lint.RuleConfig{Arguments: []any{ifelse.PreserveScope}})
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestTimeEqual rule.
|
||||
func TestTimeEqual(t *testing.T) {
|
||||
testRule(t, "time_equal", &rule.TimeEqualRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestTimeNamingRule rule.
|
||||
func TestTimeNaming(t *testing.T) {
|
||||
testRule(t, "time_naming", &rule.TimeNamingRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestUnnecessaryStmt rule.
|
||||
func TestUnnecessaryStmt(t *testing.T) {
|
||||
testRule(t, "unnecessary_stmt", &rule.UnnecessaryStmtRule{})
|
||||
}
|
||||
|
||||
@@ -6,7 +6,6 @@ import (
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// UselessBreak rule.
|
||||
func TestUselessBreak(t *testing.T) {
|
||||
testRule(t, "useless_break", &rule.UselessBreak{})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user