gitlab-qa 8.3.2 → 8.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitlab/ci/jobs/base.gitlab-ci.yml +1 -3
- data/.gitlab/ci/jobs/mtls.gitlab-ci.yml +2 -0
- data/Gemfile.lock +1 -1
- data/lib/gitlab/qa/component/specs.rb +14 -6
- data/lib/gitlab/qa/report/report_as_issue.rb +3 -3
- data/lib/gitlab/qa/runtime/env.rb +2 -1
- data/lib/gitlab/qa/scenario/test/instance/deployment_base.rb +0 -5
- data/lib/gitlab/qa/support/gitlab_version_info.rb +4 -1
- data/lib/gitlab/qa/version.rb +1 -1
- data/lib/gitlab/qa.rb +1 -0
- 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: ae27f1af0edb9ce83b3ba33e8f18ddb155b62a786b7977d93ab74dfe2ba33e77
|
4
|
+
data.tar.gz: 45f26af4e1796502625888791990c16403654f1abe9558deca1d7fc351135383
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4b7e606c2e6966d29ddc414e512ad7c2ce19a67dcf9ef20fcdaec5575219aa82631cb77c486e35c74f1a4c956004b6f7519f6422838a09d8e43873a5e9c4bbb4
|
7
|
+
data.tar.gz: 7ebbdd74ef735ecbdcb107bafa1418754f3cc89b18d72da2986b0d0d455145e25e4e4c812ab2d2dcbc72e4d50b2337d5f60d66100d715bbd6d3e4750f9eb9c22
|
@@ -2,6 +2,7 @@ ce:mtls:
|
|
2
2
|
extends:
|
3
3
|
- .rules:ce-never-when-triggered-by-feature-flag-definition-change
|
4
4
|
- .test
|
5
|
+
- .high-capacity
|
5
6
|
- .ce-variables
|
6
7
|
- .rspec-report-opts
|
7
8
|
variables:
|
@@ -11,6 +12,7 @@ ee:mtls:
|
|
11
12
|
extends:
|
12
13
|
- .rules:ee-never-when-triggered-by-feature-flag-definition-change
|
13
14
|
- .test
|
15
|
+
- .high-capacity
|
14
16
|
- .ee-variables
|
15
17
|
- .rspec-report-opts
|
16
18
|
variables:
|
data/Gemfile.lock
CHANGED
@@ -14,8 +14,14 @@ module Gitlab
|
|
14
14
|
|
15
15
|
def initialize
|
16
16
|
@docker = Docker::Engine.new(stream_output: true) # stream test output directly instead of through logger
|
17
|
-
@volumes = {}
|
18
17
|
@env = {}
|
18
|
+
@volumes = {}
|
19
|
+
@default_volumes = { '/var/run/docker.sock' => '/var/run/docker.sock' }
|
20
|
+
return if Runtime::Env.qa_knapsack_report_path.blank?
|
21
|
+
|
22
|
+
@default_volumes[Runtime::Env.qa_knapsack_report_path] = File.join(
|
23
|
+
Docker::Volumes::QA_CONTAINER_WORKDIR, 'knapsack'
|
24
|
+
)
|
19
25
|
end
|
20
26
|
|
21
27
|
def perform
|
@@ -59,12 +65,12 @@ module Gitlab
|
|
59
65
|
command.env(key, value)
|
60
66
|
end
|
61
67
|
|
62
|
-
command.volume(
|
63
|
-
|
68
|
+
command.volume(
|
69
|
+
File.join(Runtime::Env.host_artifacts_dir, name),
|
70
|
+
File.join(Docker::Volumes::QA_CONTAINER_WORKDIR, 'tmp')
|
71
|
+
)
|
64
72
|
|
65
|
-
|
66
|
-
command.volume(to, from)
|
67
|
-
end
|
73
|
+
volumes.to_h.merge(default_volumes).each { |to, from| command.volume(to, from) }
|
68
74
|
|
69
75
|
command.name(name)
|
70
76
|
end
|
@@ -73,6 +79,8 @@ module Gitlab
|
|
73
79
|
|
74
80
|
private
|
75
81
|
|
82
|
+
attr_reader :default_volumes
|
83
|
+
|
76
84
|
def docker_pull_qa_image_if_needed
|
77
85
|
@docker.login(**release.login_params) if release.login_params
|
78
86
|
|
@@ -159,14 +159,14 @@ module Gitlab
|
|
159
159
|
# Gets the name of the pipeline the test was run in, to be used as the key of a scoped label
|
160
160
|
#
|
161
161
|
# Tests can be run in several pipelines:
|
162
|
-
# gitlab
|
162
|
+
# gitlab, nightly, staging, canary, production, preprod, MRs, and the default branch (master/main)
|
163
163
|
#
|
164
164
|
# Some of those run in their own project, so CI_PROJECT_NAME is the name we need. Those are:
|
165
165
|
# nightly, staging, canary, production, and preprod
|
166
166
|
#
|
167
|
-
# MR, master/main, and gitlab
|
167
|
+
# MR, master/main, and gitlab tests run in gitlab-qa, but we only want to report tests run on
|
168
168
|
# master/main because the other pipelines will be monitored by the author of the MR that triggered them.
|
169
|
-
# So we assume that we're reporting a master/main pipeline if the project name is 'gitlab
|
169
|
+
# So we assume that we're reporting a master/main pipeline if the project name is 'gitlab'.
|
170
170
|
|
171
171
|
@pipeline ||= Runtime::Env.pipeline_from_project_name
|
172
172
|
end
|
@@ -81,6 +81,7 @@ module Gitlab
|
|
81
81
|
'KNAPSACK_TEST_FILE_PATTERN' => :knapsack_test_file_pattern,
|
82
82
|
'KNAPSACK_TEST_DIR' => :knapsack_test_dir,
|
83
83
|
'QA_KNAPSACK_REPORT_GCS_CREDENTIALS' => :qa_knapsack_report_gcs_credentials,
|
84
|
+
'QA_KNAPSACK_REPORT_PATH' => :qa_knapsack_report_path,
|
84
85
|
'CI' => :ci,
|
85
86
|
'CI_COMMIT_REF_NAME' => :ci_commit_ref_name,
|
86
87
|
'CI_JOB_NAME' => :ci_job_name,
|
@@ -198,7 +199,7 @@ module Gitlab
|
|
198
199
|
end
|
199
200
|
|
200
201
|
def pipeline_from_project_name
|
201
|
-
ci_project_name.to_s.start_with?('gitlab
|
202
|
+
ci_project_name.to_s.start_with?('gitlab') ? QA::Runtime::Env.default_branch : ci_project_name
|
202
203
|
end
|
203
204
|
|
204
205
|
def run_id
|
@@ -29,7 +29,6 @@ module Gitlab
|
|
29
29
|
specs.suite = @suite
|
30
30
|
specs.release = release
|
31
31
|
specs.args = non_rspec_args.push(*args)
|
32
|
-
specs.volumes[host_knapsack_report_path] = "/home/gitlab/qa/knapsack" if host_knapsack_report_path
|
33
32
|
end
|
34
33
|
end
|
35
34
|
|
@@ -40,10 +39,6 @@ module Gitlab
|
|
40
39
|
def deployment_component
|
41
40
|
raise NotImplementedError, 'Please define the Component for the deployment environment associated with this scenario.'
|
42
41
|
end
|
43
|
-
|
44
|
-
def host_knapsack_report_path
|
45
|
-
ENV["QA_KNAPSACK_REPORT_PATH"]
|
46
|
-
end
|
47
42
|
end
|
48
43
|
end
|
49
44
|
end
|
@@ -155,12 +155,13 @@ module Gitlab
|
|
155
155
|
# All available docker tags
|
156
156
|
#
|
157
157
|
# @return [Array<String>]
|
158
|
+
# rubocop:disable Metrics/AbcSize
|
158
159
|
def tags
|
159
160
|
return @tags if defined?(@tags)
|
160
161
|
|
161
162
|
logger.info("Fetching docker tags from 'gitlab/gitlab-#{edition}' registry")
|
162
163
|
response = HttpRequest.make_http_request(
|
163
|
-
url: "https://registry.hub.docker.com/
|
164
|
+
url: "https://registry.hub.docker.com/v2/namespaces/gitlab/repositories/gitlab-#{edition}/tags?page_size=1000",
|
164
165
|
fail_on_error: false
|
165
166
|
)
|
166
167
|
|
@@ -171,9 +172,11 @@ module Gitlab
|
|
171
172
|
|
172
173
|
@tags = JSON
|
173
174
|
.parse(response.body, symbolize_names: true)
|
175
|
+
.fetch(:results)
|
174
176
|
.map { |tag| tag[:name] }
|
175
177
|
.select { |tag| tag.match?(VERSION_PATTERN) }
|
176
178
|
end
|
179
|
+
# rubocop:enable Metrics/AbcSize
|
177
180
|
end
|
178
181
|
end
|
179
182
|
end
|
data/lib/gitlab/qa/version.rb
CHANGED
data/lib/gitlab/qa.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gitlab-qa
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 8.
|
4
|
+
version: 8.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GitLab Quality
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-09-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: climate_control
|