Skip to content

Commit

Permalink
add github actions attestations scope to write-all (#62)
Browse files Browse the repository at this point in the history
  • Loading branch information
becojo authored May 7, 2024
1 parent cb6ce21 commit e0d6048
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions models/github_actions.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
const (
ScopeMetadata = "metadata"
ScopeActions = "actions"
ScopeAttestations = "attestations"
ScopeChecks = "checks"
ScopeContents = "contents"
ScopeDeployments = "deployments"
Expand All @@ -30,6 +31,7 @@ const (
var AllScopes = []string{
ScopeMetadata,
ScopeActions,
ScopeAttestations,
ScopeChecks,
ScopeContents,
ScopeDeployments,
Expand Down
1 change: 1 addition & 0 deletions models/github_actions_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,7 @@ jobs:
// write-all is normalized to all scopes
assert.Contains(t, workflow.Permissions, GithubActionsPermission{Scope: "metadata", Permission: "write"})
assert.Contains(t, workflow.Permissions, GithubActionsPermission{Scope: "contents", Permission: "write"})
assert.Contains(t, workflow.Permissions, GithubActionsPermission{Scope: "attestations", Permission: "write"})

assert.Equal(t, "build", workflow.Jobs[0].Outputs[0].Name)
assert.Equal(t, "${{ steps.checkout.outputs.build }}", workflow.Jobs[0].Outputs[0].Value)
Expand Down

0 comments on commit e0d6048

Please sign in to comment.