Loading
feat: add Jobs field to ProjectLintResult
Closes #2340 (closed)
Description
The CI Lint API (POST /projects/:id/ci/lint and GET /projects/:id/ci/lint) returns job definitions when include_jobs=true.
While ProjectNamespaceLintOptions and ProjectLintOptions already support IncludeJobs, ProjectLintResult was missing the jobs field.
This MR:
- Adds
ProjectLintJobstruct (name,stage,before_script,script,after_script). - Adds
Jobs []ProjectLintJobtoProjectLintResult.
API Reference: https://docs.gitlab.com/api/lint/#validate-cicd-configuration
Testing
- Added test coverage in
validate_test.goforTestValidateProjectNamespaceandTestValidateProjectLint. go test -race ./...andgolangci-lint run .pass.