(options)
| 67 | } |
| 68 | |
| 69 | static optionsToBody (options) { |
| 70 | const { file, project, environment } = options |
| 71 | const trustConfig = { |
| 72 | type: 'gitlab', |
| 73 | claims: { |
| 74 | project_path: project, |
| 75 | // this looks off, but this is correct |
| 76 | /** The ref path to the top-level pipeline definition, for example, gitlab.example.com/my-group/my-project//.gitlab-ci.yml@refs/heads/main. Introduced in GitLab 16.2. This claim is null unless the pipeline definition is located in the same project. */ |
| 77 | ci_config_ref_uri: { |
| 78 | file, |
| 79 | }, |
| 80 | ...(environment) && { environment }, |
| 81 | }, |
| 82 | } |
| 83 | return trustConfig |
| 84 | } |
| 85 | |
| 86 | // Convert API response body to options |
| 87 | static bodyToOptions (body) { |
no outgoing calls
no test coverage detected