Commit ba05d2a3 authored by Rémy Coutable's avatar Rémy Coutable

Test against PG11 in MRs/master/nightly, and PG10 in master/nightly

The long-term testing strategy will be documented soon, see
https://gitlab.com/gitlab-org/gitlab/-/issues/213696.
Signed-off-by: default avatarRémy Coutable <remy@rymai.me>
parent e28388c9
......@@ -3,9 +3,9 @@
- .default-retry
- .default-cache
- .default-before_script
- .use-pg10
- .use-pg11
stage: test
needs: ["setup-test-env pg10"]
needs: ["setup-test-env pg11"]
variables:
FIXTURE_PATH: "db/fixtures/development"
SEED_CYCLE_ANALYTICS: "true"
......@@ -26,7 +26,7 @@ run-dev-fixtures-ee:
extends:
- .run-dev-fixtures
- .dev-fixtures:rules:ee-only
- .use-pg10-ee
- .use-pg11-ee
script:
- scripts/gitaly-test-spawn
- cp ee/db/fixtures/development/* $FIXTURE_PATH
......
......@@ -66,9 +66,9 @@ graphql-reference-verify:
- .default-cache
- .default-before_script
- .docs:rules:graphql-reference-verify
- .use-pg10
- .use-pg11
stage: test
needs: ["setup-test-env pg10"]
needs: ["setup-test-env pg11"]
script:
- bundle exec rake gitlab:graphql:check_docs
- bundle exec rake gitlab:graphql:check_schema
......@@ -129,9 +129,9 @@ compile-assets pull-cache as-if-foss:
- .default-retry
- .default-cache
- .default-before_script
- .use-pg10
- .use-pg11
stage: fixtures
needs: ["setup-test-env pg10", "compile-assets pull-cache"]
needs: ["setup-test-env pg11", "compile-assets pull-cache"]
script:
- date
- scripts/gitaly-test-spawn
......@@ -289,7 +289,7 @@ webpack-dev-server:
- .default-cache
- .frontend:rules:default-frontend-jobs
stage: test
needs: ["setup-test-env pg10", "compile-assets pull-cache"]
needs: ["setup-test-env pg11", "compile-assets pull-cache"]
variables:
WEBPACK_MEMORY_TEST: "true"
WEBPACK_VENDOR_DLL: "true"
......
......@@ -21,7 +21,7 @@
# Jobs that only need to pull cache
.default-cache:
cache:
key: "debian-stretch-ruby-2.6.5-pg10-node-12.x"
key: "debian-stretch-ruby-2.6.5-pg11-node-12.x"
paths:
- .go/pkg/mod
- vendor/ruby
......
......@@ -8,7 +8,7 @@
memory-static:
extends: .only-code-memory-job-base
stage: test
needs: ["setup-test-env pg10"]
needs: ["setup-test-env pg11"]
variables:
SETUP_DB: "false"
script:
......@@ -36,9 +36,9 @@ memory-static:
memory-on-boot:
extends:
- .only-code-memory-job-base
- .use-pg10
- .use-pg11
stage: test
needs: ["setup-test-env pg10", "compile-assets pull-cache"]
needs: ["setup-test-env pg11", "compile-assets pull-cache"]
variables:
NODE_ENV: "production"
RAILS_ENV: "production"
......
.rails:needs:setup-and-assets:
needs: ["setup-test-env pg10", "compile-assets pull-cache"]
needs: ["setup-test-env pg11", "compile-assets pull-cache"]
.rails-job-base:
extends:
......@@ -25,17 +25,17 @@
cache:
policy: pull-push
setup-test-env pg10:
setup-test-env pg11:
extends:
- .base-setup-test-env
- .rails:rules:default-refs-code-backstage-qa
- .use-pg10
- .use-pg11
setup-test-env pg11:
setup-test-env pg10:
extends:
- .base-setup-test-env
- .rails:rules:master-refs-code-backstage
- .use-pg11
- .use-pg10
setup-test-env pg9:
extends:
......@@ -55,7 +55,7 @@ static-analysis:
script:
- scripts/static-analysis
cache:
key: "ruby-2.6.5-pg10-rubocop"
key: "ruby-2.6.5-pg11-rubocop"
paths:
- vendor/ruby
- tmp/rubocop_cache
......@@ -75,7 +75,7 @@ downtime_check:
.rspec-base:
extends: .rails-job-base
stage: test
needs: ["setup-test-env pg10", "retrieve-tests-metadata", "compile-assets pull-cache"]
needs: ["setup-test-env pg11", "retrieve-tests-metadata", "compile-assets pull-cache"]
script:
- source scripts/rspec_helpers.sh
- rspec_paralellized_job "--tag ~quarantine --tag ~geo --tag ~level:migration"
......@@ -93,10 +93,10 @@ downtime_check:
reports:
junit: junit_rspec.xml
.rspec-base-quarantine-pg10:
.rspec-base-quarantine-pg11:
extends:
- .rspec-base
- .use-pg10
- .use-pg11
variables:
RSPEC_OPTS: "--tag quarantine -- spec/"
script:
......@@ -104,37 +104,37 @@ downtime_check:
- rspec_simple_job "${RSPEC_OPTS}"
allow_failure: true
.rspec-base-pg10:
.rspec-base-pg11:
extends:
- .rspec-base
- .rails:rules:ee-and-foss
- .use-pg10
- .use-pg11
.rspec-base-migration:
script:
- source scripts/rspec_helpers.sh
- rspec_paralellized_job "--tag ~quarantine --tag ~geo --tag level:migration"
rspec migration pg10:
rspec migration pg11:
extends:
- .rspec-base-pg10
- .rspec-base-pg11
- .rspec-base-migration
parallel: 5
rspec unit pg10:
extends: .rspec-base-pg10
rspec unit pg11:
extends: .rspec-base-pg11
parallel: 20
rspec integration pg10:
extends: .rspec-base-pg10
rspec integration pg11:
extends: .rspec-base-pg11
parallel: 8
rspec system pg10:
extends: .rspec-base-pg10
rspec system pg11:
extends: .rspec-base-pg11
parallel: 24
rspec fast_spec_helper:
extends: .rspec-base-pg10
extends: .rspec-base-pg11
script:
- bin/rspec spec/fast_spec_helper.rb
......@@ -142,9 +142,9 @@ rspec fast_spec_helper:
extends:
- .rails-job-base
- .rails:rules:ee-and-foss
- .use-pg10
- .use-pg11
stage: test
needs: ["setup-test-env pg10"]
needs: ["setup-test-env pg11"]
db:migrate:reset:
extends: .db-job-base
......@@ -213,18 +213,18 @@ rspec:coverage:
# We cannot use needs since it would mean needing 84 jobs (since most are parallelized)
# so we use `dependencies` here.
dependencies:
- setup-test-env pg10
- rspec migration pg10
- rspec unit pg10
- rspec integration pg10
- rspec system pg10
- rspec-ee migration pg10
- rspec-ee unit pg10
- rspec-ee integration pg10
- rspec-ee system pg10
- rspec-ee unit pg10 geo
- rspec-ee integration pg10 geo
- rspec-ee system pg10 geo
- setup-test-env pg11
- rspec migration pg11
- rspec unit pg11
- rspec integration pg11
- rspec system pg11
- rspec-ee migration pg11
- rspec-ee unit pg11
- rspec-ee integration pg11
- rspec-ee system pg11
- rspec-ee unit pg11 geo
- rspec-ee integration pg11 geo
- rspec-ee system pg11 geo
- memory-static
- memory-on-boot
variables:
......@@ -247,34 +247,34 @@ rspec:coverage:
####################
# master-only jobs #
rspec quarantine pg10:
rspec quarantine pg11:
extends:
- .rspec-base-quarantine-pg10
- .rspec-base-quarantine-pg11
- .rails:rules:master-refs-code-backstage
.rspec-base-pg11:
.rspec-base-pg10:
extends:
- .rspec-base
- .rails:rules:master-refs-code-backstage
- .use-pg11
needs: ["setup-test-env pg11", "retrieve-tests-metadata", "compile-assets pull-cache"]
- .use-pg10
needs: ["setup-test-env pg10", "retrieve-tests-metadata", "compile-assets pull-cache"]
rspec migration pg11:
rspec migration pg10:
extends:
- .rspec-base-pg11
- .rspec-base-pg10
- .rspec-base-migration
parallel: 5
rspec unit pg11:
extends: .rspec-base-pg11
rspec unit pg10:
extends: .rspec-base-pg10
parallel: 20
rspec integration pg11:
extends: .rspec-base-pg11
rspec integration pg10:
extends: .rspec-base-pg10
parallel: 8
rspec system pg11:
extends: .rspec-base-pg11
rspec system pg10:
extends: .rspec-base-pg10
parallel: 24
# master-only jobs #
####################
......@@ -310,41 +310,41 @@ rspec system pg9:
#######################
# EE master-only jobs #
rspec-ee quarantine pg10:
rspec-ee quarantine pg11:
extends:
- .rspec-base-quarantine-pg10
- .rspec-base-quarantine-pg11
- .rails:rules:master-refs-code-backstage-ee-only
variables:
RSPEC_OPTS: "--tag quarantine -- ee/spec/"
.rspec-ee-base-pg11:
.rspec-ee-base-pg10:
extends:
- .rspec-base-ee
- .use-pg11-ee
needs: ["setup-test-env pg11", "retrieve-tests-metadata", "compile-assets pull-cache"]
- .use-pg10-ee
needs: ["setup-test-env pg10", "retrieve-tests-metadata", "compile-assets pull-cache"]
rspec-ee migration pg11:
rspec-ee migration pg10:
extends:
- .rspec-ee-base-pg11
- .rspec-ee-base-pg10
- .rspec-base-migration
- .rails:rules:master-refs-code-backstage
parallel: 2
rspec-ee unit pg11:
rspec-ee unit pg10:
extends:
- .rspec-ee-base-pg11
- .rspec-ee-base-pg10
- .rails:rules:master-refs-code-backstage
parallel: 10
rspec-ee integration pg11:
rspec-ee integration pg10:
extends:
- .rspec-ee-base-pg11
- .rspec-ee-base-pg10
- .rails:rules:master-refs-code-backstage
parallel: 4
rspec-ee system pg11:
rspec-ee system pg10:
extends:
- .rspec-ee-base-pg11
- .rspec-ee-base-pg10
- .rails:rules:master-refs-code-backstage
parallel: 6
# EE master-only jobs #
......@@ -357,52 +357,52 @@ rspec-ee system pg11:
- .rspec-base
- .rails:rules:ee-only
.rspec-base-pg10-as-if-foss:
.rspec-base-pg11-as-if-foss:
extends:
- .rspec-base-ee
- .as-if-foss
- .use-pg10
needs: ["setup-test-env pg10", "retrieve-tests-metadata", "compile-assets pull-cache as-if-foss"]
- .use-pg11
needs: ["setup-test-env pg11", "retrieve-tests-metadata", "compile-assets pull-cache as-if-foss"]
.rspec-ee-base-pg10:
.rspec-ee-base-pg11:
extends:
- .rspec-base-ee
- .use-pg10-ee
- .use-pg11-ee
rspec migration pg10-as-if-foss:
rspec migration pg11-as-if-foss:
extends:
- .rspec-base-pg10-as-if-foss
- .rspec-base-pg11-as-if-foss
- .rspec-base-migration
parallel: 5
rspec unit pg10-as-if-foss:
extends: .rspec-base-pg10-as-if-foss
rspec unit pg11-as-if-foss:
extends: .rspec-base-pg11-as-if-foss
parallel: 20
rspec integration pg10-as-if-foss:
extends: .rspec-base-pg10-as-if-foss
rspec integration pg11-as-if-foss:
extends: .rspec-base-pg11-as-if-foss
parallel: 8
rspec system pg10-as-if-foss:
extends: .rspec-base-pg10-as-if-foss
rspec system pg11-as-if-foss:
extends: .rspec-base-pg11-as-if-foss
parallel: 24
rspec-ee migration pg10:
rspec-ee migration pg11:
extends:
- .rspec-ee-base-pg10
- .rspec-ee-base-pg11
- .rspec-base-migration
parallel: 2
rspec-ee unit pg10:
extends: .rspec-ee-base-pg10
rspec-ee unit pg11:
extends: .rspec-ee-base-pg11
parallel: 10
rspec-ee integration pg10:
extends: .rspec-ee-base-pg10
rspec-ee integration pg11:
extends: .rspec-ee-base-pg11
parallel: 4
rspec-ee system pg10:
extends: .rspec-ee-base-pg10
rspec-ee system pg11:
extends: .rspec-ee-base-pg11
parallel: 6
.rspec-ee-base-geo:
......@@ -412,20 +412,20 @@ rspec-ee system pg10:
- scripts/prepare_postgres_fdw.sh
- rspec_paralellized_job "--tag ~quarantine --tag geo"
.rspec-ee-base-geo-pg10:
.rspec-ee-base-geo-pg11:
extends:
- .rspec-ee-base-geo
- .use-pg10-ee
- .use-pg11-ee
rspec-ee unit pg10 geo:
extends: .rspec-ee-base-geo-pg10
rspec-ee unit pg11 geo:
extends: .rspec-ee-base-geo-pg11
parallel: 2
rspec-ee integration pg10 geo:
extends: .rspec-ee-base-geo-pg10
rspec-ee integration pg11 geo:
extends: .rspec-ee-base-geo-pg11
rspec-ee system pg10 geo:
extends: .rspec-ee-base-geo-pg10
rspec-ee system pg11 geo:
extends: .rspec-ee-base-geo-pg11
db:rollback geo:
extends:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment