Skip to content

E2E: Add Orchestrated code_suggestions_spec

What does this MR do and why?

Relates to https://gitlab.com/gitlab-org/quality/quality-engineering/team-tasks/-/issues/2128

This MR updates qa/specs/features/ee/api/14_model_ops/code_suggestions_spec.rb to contain new contexts that will allow it to run for both SaaS and Self-managed environments.

The SaaS context will only run against Staging-Canary, Staging, Canary and Production, where the necessary setup has already been configured on these environments (same as the current code_suggestions_spec today).

The Self-managed context will only run in e2e-package-and-test pipelines within two new jobs named ai-gateway-sync-seat-link and ai-gateway-sync-service-token (added in this MR), which will use the new Test::Integration::AiGateway scenario added to gitlab-qa. The ai-gateway-sync-service-token job differs only in that it enables the use_sync_service_token_worker feature flag during setup.

Test pipelines:

Important This MR can only be merged after the following:

  • gitlab-qa!1247 (merged) has been merged to gitlab-qa and a new version of the gitlab-qa gem has been released.
  • !139861 (merged) has been merged to bump gitlab-qa to version 13.1.0 in the GitLab project

Screenshots or screen recordings

N/A

How to set up and validate locally

  1. Check out this branch locally
  2. Export the following env vars:
export GITLAB_LICENSE_MODE=test
export QA_EE_ACTIVATION_CODE=<value from 1Password>
export QA_SKIP_PULL=true
  1. Build the QA image with
docker build -t gitlab/gitlab-ee-qa:your-custom-tag --file ./qa/Dockerfile ./
  1. Tag the current nightly build for the corresponding GitLab image
docker tag gitlab/gitlab-ee:nightly gitlab/gitlab-ee:your-custom-tag
  1. If !139861 (merged) has still not been merged, you may need to update your Gemfile and Gemfile.lock to bump gitlab-qa to version 13.1.0
  2. Run the following from the qa directory:
gitlab-qa Test::Integration::AiGateway gitlab/gitlab-ee:your-custom-tag

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Valerie Burton

Merge request reports

Loading