gitlab-qa 6.16.0 → 6.17.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 12907bedff5302d7716d94e3e9cdc5629a03feeccbab102bc3feabf477240355
4
- data.tar.gz: 224a6d60f40826634d06abc1ebcccaff688fc4e38bf3d6f8a8ab253f289daaaa
3
+ metadata.gz: fc3ae23427dadce6649bb30dbc58dada153af79f60efb265edd5f7439facc56f
4
+ data.tar.gz: 9308ba475631df203f08503929787c1015fb4313b455d30a8fee2175016b1429
5
5
  SHA512:
6
- metadata.gz: c657c2f07960e1d27e0c0db79730941586ecbe5b5a46b5a66b7059524f200f7b51fa40c1b01083b56649b4791462974da1dc5b1865282897c3a3b62892ad73f7
7
- data.tar.gz: c16b9320f6b6b388754acdf70e532414fcd1344739aad13f5a64cee2905c9d2c3af79796ac5a3756581cf02d6da893eb560dbe9c682d3c655dba0871c592be7d
6
+ metadata.gz: 89c9c13ae10ff6e8f0076fb02d365cb45ede7320901bc5b4e4ca25ae935b9af26bc7da4d48bdab172ea6c3b74092032e5c9c5f04704ee7f98b38b67a594f81e5
7
+ data.tar.gz: 246f02d2389dd6db83ee1aac5e7dbc3e95ebfb12f9524f11181decf68ec5c9906adaa88531da62f66c2037c800de86084e4741193c3eaced1229ce135610fb1b
@@ -42,9 +42,6 @@ variables:
42
42
  QA_CAN_TEST_GIT_PROTOCOL_V2: "true"
43
43
  QA_CAN_TEST_PRAEFECT: "false"
44
44
  QA_TESTCASES_REPORTING_PROJECT: "gitlab-org/quality/testcases"
45
- QA_FAILURES_REPORTING_PROJECT: "rymai/gitlab-qa-issues"
46
- # The --dry-run or --max-diff-ratio option can be set to modify the behavior of `exe/gitlab-qa-report --relate-failure-issue` without releasing a new gem version.
47
- QA_FAILURES_REPORTER_OPTIONS: ""
48
45
  QA_TESTCASE_SESSIONS_PROJECT: "gitlab-org/quality/testcase-sessions"
49
46
  # QA_DEFAULT_BRANCH is the default branch name of the instance under test.
50
47
  QA_DEFAULT_BRANCH: "master"
@@ -82,7 +79,6 @@ rspec:
82
79
  - exe/gitlab-qa-report --update-screenshot-path "gitlab-qa-run-*/**/rspec-*.xml"
83
80
  - export GITLAB_QA_ACCESS_TOKEN="$GITLAB_QA_PRODUCTION_ACCESS_TOKEN"
84
81
  - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --report-in-issues "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_TESTCASES_REPORTING_PROJECT" || true; fi
85
- - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --relate-failure-issue "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_FAILURES_REPORTING_PROJECT" $QA_FAILURES_REPORTER_OPTIONS || true; fi
86
82
  - exit $test_run_exit_code
87
83
 
88
84
  .ce-qa:
@@ -337,7 +333,6 @@ ce:update:
337
333
  - exe/gitlab-qa Test::Omnibus::Update ${RELEASE:=CE} ${RELEASE:=CE} -- $RSPEC_REPORT_OPTS || test_run_exit_code=$?
338
334
  - export GITLAB_QA_ACCESS_TOKEN="$GITLAB_QA_PRODUCTION_ACCESS_TOKEN"
339
335
  - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --report-in-issues "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_TESTCASES_REPORTING_PROJECT" || true; fi
340
- - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --relate-failure-issue "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_FAILURES_REPORTING_PROJECT" $QA_FAILURES_REPORTER_OPTIONS || true; fi
341
336
  - exit $test_run_exit_code
342
337
  extends:
343
338
  - .test
@@ -352,7 +347,6 @@ ce:update-quarantine:
352
347
  - exe/gitlab-qa Test::Omnibus::Update ${RELEASE:=CE} ${RELEASE:=CE} -- --tag quarantine --tag ~orchestrated $RSPEC_REPORT_OPTS || test_run_exit_code=$?
353
348
  - export GITLAB_QA_ACCESS_TOKEN="$GITLAB_QA_PRODUCTION_ACCESS_TOKEN"
354
349
  - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --report-in-issues "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_TESTCASES_REPORTING_PROJECT" || true; fi
355
- - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --relate-failure-issue "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_FAILURES_REPORTING_PROJECT" $QA_FAILURES_REPORTER_OPTIONS || true; fi
356
350
  - exit $test_run_exit_code
357
351
  extends:
358
352
  - .test
@@ -366,7 +360,6 @@ ee:update:
366
360
  - exe/gitlab-qa Test::Omnibus::Update ${RELEASE:=EE} ${RELEASE:=EE} -- $RSPEC_REPORT_OPTS || test_run_exit_code=$?
367
361
  - export GITLAB_QA_ACCESS_TOKEN="$GITLAB_QA_PRODUCTION_ACCESS_TOKEN"
368
362
  - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --report-in-issues "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_TESTCASES_REPORTING_PROJECT" || true; fi
369
- - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --relate-failure-issue "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_FAILURES_REPORTING_PROJECT" $QA_FAILURES_REPORTER_OPTIONS || true; fi
370
363
  - exit $test_run_exit_code
371
364
  extends:
372
365
  - .test
@@ -381,7 +374,6 @@ ee:update-quarantine:
381
374
  - exe/gitlab-qa Test::Omnibus::Update ${RELEASE:=EE} ${RELEASE:=EE} -- --tag quarantine --tag ~orchestrated $RSPEC_REPORT_OPTS || test_run_exit_code=$?
382
375
  - export GITLAB_QA_ACCESS_TOKEN="$GITLAB_QA_PRODUCTION_ACCESS_TOKEN"
383
376
  - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --report-in-issues "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_TESTCASES_REPORTING_PROJECT" || true; fi
384
- - if [ "$TOP_UPSTREAM_SOURCE_REF" == $TOP_UPSTREAM_DEFAULT_BRANCH ] || [[ "$TOP_UPSTREAM_SOURCE_JOB" == https://ops.gitlab.net* ]]; then exe/gitlab-qa-report --relate-failure-issue "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_FAILURES_REPORTING_PROJECT" $QA_FAILURES_REPORTER_OPTIONS || true; fi
385
377
  - exit $test_run_exit_code
386
378
  extends:
387
379
  - .test
@@ -469,22 +461,23 @@ ee:mattermost-quarantine:
469
461
  variables:
470
462
  QA_SCENARIO: "Test::Integration::Mattermost"
471
463
 
472
- ee:geo:
473
- extends:
474
- - .test
475
- - .ee-qa
476
- - .rspec-report-opts
477
- variables:
478
- QA_SCENARIO: "Test::Integration::Geo"
479
-
480
- ee:geo-quarantine:
481
- extends:
482
- - .test
483
- - .ee-qa
484
- - .quarantine
485
- - .rspec-report-opts
486
- variables:
487
- QA_SCENARIO: "Test::Integration::Geo"
464
+ # Disabling geo jobs temporarily due to https://gitlab.com/gitlab-org/gitlab/-/issues/273063
465
+ # ee:geo:
466
+ # extends:
467
+ # - .test
468
+ # - .ee-qa
469
+ # - .rspec-report-opts
470
+ # variables:
471
+ # QA_SCENARIO: "Test::Integration::Geo"
472
+
473
+ # ee:geo-quarantine:
474
+ # extends:
475
+ # - .test
476
+ # - .ee-qa
477
+ # - .quarantine
478
+ # - .rspec-report-opts
479
+ # variables:
480
+ # QA_SCENARIO: "Test::Integration::Geo"
488
481
 
489
482
  ce:ldap_no_tls:
490
483
  extends:
@@ -963,6 +956,24 @@ generate_test_session:
963
956
  - export GITLAB_QA_ACCESS_TOKEN="$GITLAB_QA_PRODUCTION_ACCESS_TOKEN"
964
957
  - exe/gitlab-qa-report --generate-test-session "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_TESTCASE_SESSIONS_PROJECT"
965
958
 
959
+ relate_test_failures:
960
+ stage: report
961
+ rules:
962
+ - if: '$DISABLE_RELATING_FAILURE_ISSUES'
963
+ when: never
964
+ - if: '$TOP_UPSTREAM_SOURCE_JOB && $TOP_UPSTREAM_SOURCE_REF == $TOP_UPSTREAM_DEFAULT_BRANCH'
965
+ when: always
966
+ - if: '$TOP_UPSTREAM_SOURCE_JOB =~ /\Ahttps:\/\/ops.gitlab.net\//'
967
+ when: always
968
+ variables:
969
+ QA_FAILURES_REPORTING_PROJECT: "gitlab-org/gitlab"
970
+ QA_FAILURES_MAX_DIFF_RATIO: "0.05"
971
+ # The --dry-run can be set to modify the behavior of `exe/gitlab-qa-report --relate-failure-issue` without releasing a new gem version.
972
+ QA_FAILURES_REPORTER_OPTIONS: ""
973
+ script:
974
+ - export GITLAB_QA_ACCESS_TOKEN="$GITLAB_QA_PRODUCTION_ACCESS_TOKEN"
975
+ - exe/gitlab-qa-report --relate-failure-issue "gitlab-qa-run-*/**/rspec-*.json" --project "$QA_FAILURES_REPORTING_PROJECT" --max-diff-ratio "$QA_FAILURES_MAX_DIFF_RATIO" $QA_FAILURES_REPORTER_OPTIONS
976
+
966
977
  .notify_upstream_commit:
967
978
  stage: notify
968
979
  image: ruby:2.6
@@ -57,6 +57,7 @@ module Gitlab
57
57
  autoload :SMTP, 'gitlab/qa/scenario/test/integration/smtp'
58
58
  autoload :GitalyCluster, 'gitlab/qa/scenario/test/integration/gitaly_cluster'
59
59
  autoload :Jira, 'gitlab/qa/scenario/test/integration/jira'
60
+ autoload :SSHTunnel, 'gitlab/qa/scenario/test/integration/ssh_tunnel'
60
61
  end
61
62
 
62
63
  module Sanity
@@ -181,6 +181,10 @@ module Gitlab
181
181
  ENV['GITLAB_QA_DEV_ACCESS_TOKEN']
182
182
  end
183
183
 
184
+ def initial_root_password
185
+ ENV['GITLAB_INITIAL_ROOT_PASSWORD']
186
+ end
187
+
184
188
  def qa_container_registry_access_token
185
189
  ENV['GITLAB_QA_CONTAINER_REGISTRY_ACCESS_TOKEN']
186
190
  end
@@ -256,6 +260,25 @@ module Gitlab
256
260
  end
257
261
  end
258
262
 
263
+ def require_initial_password!
264
+ return unless ENV['GITLAB_INITIAL_ROOT_PASSWORD'].to_s.strip.empty?
265
+
266
+ raise ArgumentError, "Environment variable GITLAB_INITIAL_ROOT_PASSWORD must be provided to set an initial root password."
267
+ end
268
+
269
+ def require_ssh_tunnel!
270
+ %w[TUNNEL_SSH_PRIVATE_KEY TUNNEL_SERVER_HOSTNAME TUNNEL_SSH_USER].each do |env_key|
271
+ raise ArgumentError, "Environment variable #{env_key} must be set to run tunnel specs" unless ENV.key?(env_key)
272
+ end
273
+ end
274
+
275
+ def override_default_password!
276
+ require_initial_password!
277
+
278
+ ENV['GITLAB_PASSWORD'] = initial_root_password
279
+ ENV['GITLAB_ADMIN_PASSWORD'] = initial_root_password
280
+ end
281
+
259
282
  def skip_pull?
260
283
  enabled?(ENV['QA_SKIP_PULL'], default: false)
261
284
  end
@@ -0,0 +1,59 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Gitlab
4
+ module QA
5
+ module Scenario
6
+ module Test
7
+ module Integration
8
+ class SSHTunnel < Scenario::Template
9
+ # rubocop:disable Metrics/AbcSize
10
+ def perform(release, *rspec_args)
11
+ Runtime::Env.override_default_password!
12
+ Runtime::Env.require_ssh_tunnel!
13
+
14
+ Component::Gitlab.perform do |gitlab|
15
+ gitlab.release = release
16
+ gitlab.network = 'test'
17
+
18
+ Component::InternetTunnel.perform do |tunnel_gitlab|
19
+ Component::InternetTunnel.perform do |tunnel_registry|
20
+ tunnel_gitlab.gitlab_hostname = gitlab.hostname
21
+ tunnel_gitlab.network = 'test'
22
+ tunnel_registry.gitlab_hostname = gitlab.hostname
23
+ tunnel_registry.network = 'test'
24
+
25
+ gitlab.omnibus_config = <<~OMNIBUS
26
+ external_url '#{tunnel_gitlab.url}';
27
+ nginx['listen_port'] = 80;
28
+ nginx['listen_https'] = false;
29
+ # documentation: https://docs.gitlab.com/omnibus/settings/database.html#seed-the-database-fresh-installs-only
30
+ gitlab_rails['initial_root_password'] = '#{Runtime::Env.require_initial_password}'
31
+
32
+ registry_external_url '#{tunnel_registry.url}';
33
+ registry_nginx['listen_port'] = 80;
34
+ registry_nginx['listen_https'] = false;
35
+ OMNIBUS
36
+
37
+ tunnel_gitlab.instance do
38
+ tunnel_registry.instance do
39
+ gitlab.instance do
40
+ Component::Specs.perform do |specs|
41
+ specs.suite = 'Test::Integration::SSHTunnel'
42
+ specs.release = gitlab.release
43
+ specs.network = gitlab.network
44
+ specs.args = [tunnel_gitlab.url, *rspec_args]
45
+ end
46
+ end
47
+ end
48
+ end
49
+ end
50
+ end
51
+ end
52
+ end
53
+ # rubocop:enable Metrics/AbcSize
54
+ end
55
+ end
56
+ end
57
+ end
58
+ end
59
+ end
@@ -1,5 +1,5 @@
1
1
  module Gitlab
2
2
  module QA
3
- VERSION = '6.16.0'.freeze
3
+ VERSION = '6.17.0'.freeze
4
4
  end
5
5
  end
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: 6.16.0
4
+ version: 6.17.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Grzegorz Bizon
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-12-14 00:00:00.000000000 Z
11
+ date: 2020-12-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: climate_control
@@ -310,6 +310,7 @@ files:
310
310
  - lib/gitlab/qa/scenario/test/integration/praefect.rb
311
311
  - lib/gitlab/qa/scenario/test/integration/saml.rb
312
312
  - lib/gitlab/qa/scenario/test/integration/smtp.rb
313
+ - lib/gitlab/qa/scenario/test/integration/ssh_tunnel.rb
313
314
  - lib/gitlab/qa/scenario/test/omnibus/image.rb
314
315
  - lib/gitlab/qa/scenario/test/omnibus/update.rb
315
316
  - lib/gitlab/qa/scenario/test/omnibus/upgrade.rb