github.com/Johnny2210/revive@v1.0.8-0.20210625134200-febf37ccd0f5/test/cyclomatic_test.go (about) 1 package test 2 3 import ( 4 "testing" 5 6 "github.com/mgechev/revive/lint" 7 "github.com/mgechev/revive/rule" 8 ) 9 10 func TestCyclomatic(t *testing.T) { 11 testRule(t, "cyclomatic", &rule.CyclomaticRule{}, &lint.RuleConfig{ 12 Arguments: []interface{}{int64(1)}, 13 }) 14 testRule(t, "cyclomatic-2", &rule.CyclomaticRule{}, &lint.RuleConfig{ 15 Arguments: []interface{}{int64(3)}, 16 }) 17 }