mirror of
https://github.com/mgechev/revive.git
synced 2025-11-23 22:04:49 +02:00
refactor: rename blacklist to blocklist and whitelist to allowlist (#946)
* refactor: rename blacklist to blocklist and whitelist to allowlist
This commit is contained in:
committed by
GitHub
parent
af4f9ea960
commit
9abe06adfa
8
testdata/imports-blocklist-original.go
vendored
Normal file
8
testdata/imports-blocklist-original.go
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
package fixtures
|
||||
|
||||
import (
|
||||
"crypto/md5" // MATCH /should not use the following blocklisted import: "crypto/md5"/
|
||||
"crypto/sha1" // MATCH /should not use the following blocklisted import: "crypto/sha1"/
|
||||
"strings"
|
||||
)
|
||||
|
||||
19
testdata/imports-blocklist.go
vendored
Normal file
19
testdata/imports-blocklist.go
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
package fixtures
|
||||
|
||||
import (
|
||||
"github.com/full/match" // MATCH /should not use the following blocklisted import: "github.com/full/match"/
|
||||
"bithub.com/full/match"
|
||||
"github.com/full/matche"
|
||||
"wildcard/between" // MATCH /should not use the following blocklisted import: "wildcard/between"/
|
||||
"wildcard/pkg1/between" // MATCH /should not use the following blocklisted import: "wildcard/pkg1/between"/
|
||||
"wildcard/pkg1/pkg2/between" // MATCH /should not use the following blocklisted import: "wildcard/pkg1/pkg2/between"/
|
||||
"wildcard/backward" // MATCH /should not use the following blocklisted import: "wildcard/backward"/
|
||||
"wildcard/backward/pkg" // MATCH /should not use the following blocklisted import: "wildcard/backward/pkg"/
|
||||
"wildcard/backward/pkg/pkg1" // MATCH /should not use the following blocklisted import: "wildcard/backward/pkg/pkg1"/
|
||||
"wildcard/forward" // MATCH /should not use the following blocklisted import: "wildcard/forward"/
|
||||
"pkg/wildcard/forward" // MATCH /should not use the following blocklisted import: "pkg/wildcard/forward"/
|
||||
"pkg/pkg1/wildcard/forward" // MATCH /should not use the following blocklisted import: "pkg/pkg1/wildcard/forward"/
|
||||
"full" // MATCH /should not use the following blocklisted import: "full"/
|
||||
"github.com/partical/match/fully"
|
||||
"strings"
|
||||
)
|
||||
Reference in New Issue
Block a user