mirror of
https://github.com/gitleaks/gitleaks.git
synced 2026-11-30 21:24:21 +01:00
adding more tests
This commit is contained in:
1 parent
5a300c3c64
commit
d13e0fdfde
40 files changed
+842
-5
No files matched your search
+24
-5
@@ -145,13 +145,12 @@ func TestAudit(t *testing.T) {
|
||||
wantEmpty: true,
|
||||
},
|
||||
{
|
||||
// TODO UPDATE TESTS
|
||||
description: "test local repo one aws leak single commit",
|
||||
opts: options.Options{
|
||||
RepoPath: "../test_data/test_repos/test_repo_1",
|
||||
Report: "../test_data/test_local_repo_one_aws_leak_commit.json.got",
|
||||
FilesAtCommit: "6557c92612d3b35979bd426d429255b3bf9fab74",
|
||||
ReportFormat: "json",
|
||||
RepoPath: "../test_data/test_repos/test_repo_1",
|
||||
Report: "../test_data/test_local_repo_one_aws_leak_commit.json.got",
|
||||
Commit: "6557c92612d3b35979bd426d429255b3bf9fab74",
|
||||
ReportFormat: "json",
|
||||
},
|
||||
wantPath: "../test_data/test_local_repo_one_aws_leak_commit.json",
|
||||
},
|
||||
@@ -244,6 +243,26 @@ func TestAudit(t *testing.T) {
|
||||
},
|
||||
wantPath: "../test_data/test_local_owner_aws_leak_depth_2.json",
|
||||
},
|
||||
{
|
||||
description: "test local repo five files at commit",
|
||||
opts: options.Options{
|
||||
RepoPath: "../test_data/test_repos/test_repo_5",
|
||||
Report: "../test_data/test_local_repo_five_files_at_commit.json.got",
|
||||
FilesAtCommit: "a4c9fb737d5552fd96fce5cc7eedb23353ba9ed0",
|
||||
ReportFormat: "json",
|
||||
},
|
||||
wantPath: "../test_data/test_local_repo_five_files_at_commit.json",
|
||||
},
|
||||
{
|
||||
description: "test local repo five at commit",
|
||||
opts: options.Options{
|
||||
RepoPath: "../test_data/test_repos/test_repo_5",
|
||||
Report: "../test_data/test_local_repo_five_commit.json.got",
|
||||
Commit: "a4c9fb737d5552fd96fce5cc7eedb23353ba9ed0",
|
||||
ReportFormat: "json",
|
||||
},
|
||||
wantPath: "../test_data/test_local_repo_five_commit.json",
|
||||
},
|
||||
}
|
||||
|
||||
for _, test := range tests {
|
||||
|
||||
Reference in new issue
Block a user