mirror of
https://github.com/gitleaks/gitleaks.git
synced 2026-11-29 12:44:22 +01:00
more info on output and in jsonish format
This commit is contained in:
1 parent
aa15ded5c4
commit
2186f22999
5 files changed
+46
-29
No files matched your search
+5
-5
@@ -4,24 +4,24 @@ import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func init(){
|
||||
func init() {
|
||||
opts = &Options{
|
||||
Concurrency: 10,
|
||||
B64EntropyCutoff: 70,
|
||||
HexEntropyCutoff: 40,
|
||||
Entropy: false,
|
||||
Entropy: false,
|
||||
}
|
||||
}
|
||||
|
||||
func TestCheckRegex(t *testing.T) {
|
||||
var results []string
|
||||
var results []LeakElem
|
||||
checks := map[string]int{
|
||||
"aws=\"AKIALALEMEL33243OLIAE": 1,
|
||||
"aws\"afewafewafewafewaf\"": 0,
|
||||
"aws\"afewafewafewafewaf\"": 0,
|
||||
}
|
||||
|
||||
for k, v := range checks {
|
||||
results = doChecks(k)
|
||||
results = doChecks(k, "commit")
|
||||
if v != len(results) {
|
||||
t.Errorf("regexCheck failed on string %s", k)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user