replacing workflow:write scope with workflow, workflow:write is invalid.

Signed-off-by: Marco Crivellaro <marco.crive@gmail.com>
This commit is contained in:
Marco Crivellaro
2022-03-16 17:19:26 +00:00
parent 142f3a34f7
commit e0308ca6ec
3 changed files with 5 additions and 5 deletions
@@ -364,7 +364,7 @@ spec:
secretsKey: USER_OAUTH_TOKEN
additionalScopes:
github:
- workflow:write
- workflow
allowedHosts:
- github.com
...
@@ -153,11 +153,11 @@ describe('ScmAuth', () => {
githubAuth.getCredentials({
url: 'http://example.com',
additionalScope: {
customScopes: { github: ['org:read', 'workflow:write'] },
customScopes: { github: ['org:read', 'workflow'] },
},
}),
).resolves.toMatchObject({
token: 'repo read:org read:user org:read workflow:write',
token: 'repo read:org read:user org:read workflow',
});
const gitlabAuth = ScmAuth.forGitlab(mockAuthApi);
@@ -138,7 +138,7 @@ describe('RepoUrlPicker', () => {
'ui:options': {
requestUserCredentials: {
secretsKey: 'testKey',
additionalScopes: { github: ['workflow:write'] },
additionalScopes: { github: ['workflow'] },
},
},
}}
@@ -164,7 +164,7 @@ describe('RepoUrlPicker', () => {
additionalScope: {
repoWrite: true,
customScopes: {
github: ['workflow:write'],
github: ['workflow'],
},
},
});