Investigate pushing Code Suggestions Web IDE tests down the pyramid
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
MR: Pending
Description
If a change in gitlab-vscode-extension
, gitlab-web-ide
, gitlab
, or gitlab-web-ide-vscode-fork
causes an issue with Code Suggestions in the Web IDE, our tests won't catch it until we run the QA pipeline after the final merge request in the main project is merged.
Let's see if we can push this coverage down the test pyramid a bit.
Investigation
From discussion doc:
- Enrique: e2e tests in the GitLab VSCode extension https://gitlab.com/gitlab-org/gitlab-vscode-extension/-/tree/main/test/e2e?ref_type=heads. Would it be useful to look at this approach?
- ChadW: Examples of middle-of-pyramid tests from Workspaces domain:
- features spec (browser): https://gitlab.com/gitlab-org/gitlab/-/blob/e35338d4913abc685a3d2108f14c4915763e0965/ee/spec/features/remote_development/workspaces_spec.rb
- request spec (no browser): https://gitlab.com/gitlab-org/gitlab/-/blob/b4847faf7816eab25e076b1dea0ffd098e8d326e/ee/spec/requests/remote_development/integration_spec.rb
- Note how these both use a shared module (https://gitlab.com/gitlab-org/gitlab/-/blob/e35338d4913abc685a3d2108f14c4915763e0965/ee/spec/support/helpers/remote_development/integration_spec_helpers.rb ) to mock INCOMING requests which do not originate from user browser interaction (this may not apply to the Web IDE, but workspaces needs it because the gitlab agent for kubernetes initiates some of our workflows via internal APIs)
- For outgoing requests, those can be mocked at an appropriate level using normal RSpec mock mechanisms.
- This can also act as an "enemy test" of the APIs you are using from the Rails stack.
Acceptance Criteria
We need to answer these questions:
-
At what project should we add this coverage? -
Is there special tooling needed?
Outcome:
-
A well refined issue on the steps needed to resolve this problem
Edited by 🤖 GitLab Bot 🤖