mirror of
https://github.com/mgechev/revive.git
synced 2025-12-05 22:53:41 +02:00
Adds new rule empty-block (#14)
* Adds rule superfluous-else (an extension of indent-error-flow) * initial (non functional) version * empty-block working version * adds tests for empty-block rule * Adds empty-block to the rules table * code clean-up
This commit is contained in:
12
test/empty-block_test.go
Normal file
12
test/empty-block_test.go
Normal file
@@ -0,0 +1,12 @@
|
||||
package test
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/mgechev/revive/rule"
|
||||
)
|
||||
|
||||
// TestEmptyBlock rule.
|
||||
func TestEmptyBlock(t *testing.T) {
|
||||
testRule(t, "empty-block", &rule.EmptyBlockRule{})
|
||||
}
|
||||
Reference in New Issue
Block a user