gitlab_quality-test_tooling 2.19.0 → 2.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/gitlab_quality/test_tooling/gitlab_client/issues_dry_client.rb +2 -2
- data/lib/gitlab_quality/test_tooling/report/group_issues/issue_creator.rb +1 -1
- data/lib/gitlab_quality/test_tooling/report/health_problem_reporter.rb +1 -0
- data/lib/gitlab_quality/test_tooling/report/relate_failure_issue.rb +11 -7
- data/lib/gitlab_quality/test_tooling/runtime/env.rb +1 -0
- data/lib/gitlab_quality/test_tooling/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 301b5aa0e96d58b20b5151769f92daf272b941ff374e5ec3da525d37dbf5bc1f
|
4
|
+
data.tar.gz: 8086e3301800429bc6b24dc24691fa9cfea761f34eb458a09d66642623526844
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2acb748f44ccc9484322233be13debd2cda250df3745e781c4c3feb4e1e7e0f175cb515f33e99d3c69511790dee27a47e793cb8fee1cf9f6b3b95b72e76566ee
|
7
|
+
data.tar.gz: d265ef9b4c399064f515b2df7e0f2469b5604488b4ffcac90b911c337dce3ab5b41b0ebcdc1d6c6ff0102df3602dffe3dba4227611ba74a3b0b154b7b39b7ebb
|
data/Gemfile.lock
CHANGED
@@ -4,8 +4,8 @@ module GitlabQuality
|
|
4
4
|
module TestTooling
|
5
5
|
module GitlabClient
|
6
6
|
class IssuesDryClient < IssuesClient
|
7
|
-
def create_issue(title:, description:, labels:, issue_type: 'issue', confidential: false)
|
8
|
-
attrs = { description: description, labels: labels, confidential: confidential }
|
7
|
+
def create_issue(title:, description:, labels:, assignee_id: 'unknown', issue_type: 'issue', confidential: false)
|
8
|
+
attrs = { description: description, labels: labels, confidential: confidential, assignee_id: assignee_id }
|
9
9
|
|
10
10
|
puts "The following #{issue_type} would have been created:"
|
11
11
|
puts "project: #{project}, title: #{title}, attrs: #{attrs}"
|
@@ -34,7 +34,7 @@ module GitlabQuality
|
|
34
34
|
|
35
35
|
handle_gitlab_api_error("creating issue") do
|
36
36
|
issue = @client.create_issue(title: title, description: description, labels: labels.join(','))
|
37
|
-
Runtime::Logger.info "Issue created successfully: #{issue.web_url}"
|
37
|
+
Runtime::Logger.info "Issue created successfully: #{issue.web_url}" if issue&.web_url
|
38
38
|
end
|
39
39
|
end
|
40
40
|
end
|
@@ -253,6 +253,7 @@ module GitlabQuality
|
|
253
253
|
issue_url: issues.first&.web_url,
|
254
254
|
job_id: Runtime::Env.ci_job_id,
|
255
255
|
job_web_url: test.ci_job_url,
|
256
|
+
job_status: Runtime::Env.ci_job_status,
|
256
257
|
pipeline_id: Runtime::Env.ci_pipeline_id,
|
257
258
|
pipeline_ref: Runtime::Env.ci_commit_ref_name,
|
258
259
|
pipeline_web_url: Runtime::Env.ci_pipeline_url,
|
@@ -88,16 +88,20 @@ module GitlabQuality
|
|
88
88
|
def run!
|
89
89
|
puts "Reporting test failures in `#{files.join(',')}` as issues in project `#{project}` via the API at `#{Runtime::Env.gitlab_api_base}`."
|
90
90
|
|
91
|
-
if group_similar
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
91
|
+
run_with_grouping! if group_similar
|
92
|
+
|
93
|
+
return if similar_issues_grouped?
|
94
|
+
|
95
|
+
TestResults::Builder.new(token: token, project: project, file_glob: files).test_results_per_file do |test_results|
|
96
|
+
puts "=> Reporting #{test_results.count} tests in #{test_results.path}"
|
97
|
+
process_test_results(test_results)
|
98
98
|
end
|
99
99
|
end
|
100
100
|
|
101
|
+
def similar_issues_grouped?
|
102
|
+
grouper.summary[:grouped_issues].positive?
|
103
|
+
end
|
104
|
+
|
101
105
|
def grouper
|
102
106
|
@grouper ||= GitlabQuality::TestTooling::Report::GroupIssues::GroupResultsInIssues.new(
|
103
107
|
gitlab: gitlab,
|
@@ -15,6 +15,7 @@ module GitlabQuality
|
|
15
15
|
'CI_JOB_ID' => :ci_job_id,
|
16
16
|
'CI_JOB_NAME' => :ci_job_name,
|
17
17
|
'CI_JOB_URL' => :ci_job_url,
|
18
|
+
'CI_JOB_STATUS' => :ci_job_status,
|
18
19
|
'CI_PIPELINE_ID' => :ci_pipeline_id,
|
19
20
|
'CI_PIPELINE_NAME' => :ci_pipeline_name,
|
20
21
|
'CI_PIPELINE_URL' => :ci_pipeline_url,
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gitlab_quality-test_tooling
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.20.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GitLab Quality
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-08-
|
11
|
+
date: 2025-08-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: climate_control
|