Skip to content

Commit aa7260b

Browse files
Balijepalli Vamshi KrishnaBalijepalli Vamshi Krishna
authored andcommitted
add more test cases
1 parent 56e10cb commit aa7260b

File tree

2 files changed

+12
-80
lines changed

2 files changed

+12
-80
lines changed

remediation/workflow/pin/pinactions_test.go

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -298,19 +298,19 @@ func TestPinActions(t *testing.T) {
298298
exemptedActions []string
299299
pinToImmutable bool
300300
}{
301-
// {fileName: "alreadypinned.yml", wantUpdated: false, pinToImmutable: true},
302-
// {fileName: "branch.yml", wantUpdated: true, pinToImmutable: true},
303-
// {fileName: "localaction.yml", wantUpdated: true, pinToImmutable: true},
304-
// {fileName: "multiplejobs.yml", wantUpdated: true, pinToImmutable: true},
305-
// {fileName: "basic.yml", wantUpdated: true, pinToImmutable: true},
306-
// {fileName: "dockeraction.yml", wantUpdated: true, pinToImmutable: true},
307-
// {fileName: "multipleactions.yml", wantUpdated: true, pinToImmutable: true},
308-
// {fileName: "actionwithcomment.yml", wantUpdated: true, pinToImmutable: true},
309-
// {fileName: "repeatedactionwithcomment.yml", wantUpdated: true, pinToImmutable: true},
310-
// {fileName: "immutableaction-1.yml", wantUpdated: true, pinToImmutable: true},
301+
{fileName: "alreadypinned.yml", wantUpdated: false, pinToImmutable: true},
302+
{fileName: "branch.yml", wantUpdated: true, pinToImmutable: true},
303+
{fileName: "localaction.yml", wantUpdated: true, pinToImmutable: true},
304+
{fileName: "multiplejobs.yml", wantUpdated: true, pinToImmutable: true},
305+
{fileName: "basic.yml", wantUpdated: true, pinToImmutable: true},
306+
{fileName: "dockeraction.yml", wantUpdated: true, pinToImmutable: true},
307+
{fileName: "multipleactions.yml", wantUpdated: true, pinToImmutable: true},
308+
{fileName: "actionwithcomment.yml", wantUpdated: true, pinToImmutable: true},
309+
{fileName: "repeatedactionwithcomment.yml", wantUpdated: true, pinToImmutable: true},
310+
{fileName: "immutableaction-1.yml", wantUpdated: true, pinToImmutable: true},
311311
{fileName: "exemptaction.yml", wantUpdated: true, exemptedActions: []string{"actions/checkout", "rohith/*", "praveen/*", "aman-*/*", "*/seperate*"}, pinToImmutable: true},
312-
// {fileName: "donotpintoimmutable.yml", wantUpdated: true, pinToImmutable: false},
313-
// {fileName: "invertedcommas.yml", wantUpdated: true, pinToImmutable: false},
312+
{fileName: "donotpintoimmutable.yml", wantUpdated: true, pinToImmutable: false},
313+
{fileName: "invertedcommas.yml", wantUpdated: true, pinToImmutable: false},
314314
}
315315
for _, tt := range tests {
316316

testfiles/pinactions/output/exemptaction.yml.failed

Lines changed: 0 additions & 68 deletions
This file was deleted.

0 commit comments

Comments
 (0)