Adds additional test projects for the spec to use
What does this MR do and why?
- Adds ability for the spec to find a clean group to use for the spec. I introduced 4 additional test groups that are pre-configured to hit the limit once the test runs and a helper method goes through the groups to find an available group to use.
- Combines the 2 specs (hitting the limit and going below the limit) to save a bit of time when running this spec file. The test that verifies that the test goes back into full-access mode initially has to go over the limit first anyway so might as well verify that it switches to read-only mode and deletion of the test project created results in reverting to full-access mode.
Closes #438822 (closed)
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
How to set up and validate locally
- Configure the necessary environment variables to run this against staging.
- Run the spec
bundle exec rspec qa/specs/features/ee/browser_ui/11_fulfillment/utilization/namespace_storage_limit_spec.rb
If you want to test the available_group_path
helper and make sure it is able to use the other groups, you can do the following:
- Login to the Staging
gitlab-qa
user (credentials in 1Password) - Navigate to the groups you don't want it to run on quality-e2e-tests, quality-e2e-tests-2, quality-e2e-tests-3, quality-e2e-tests-4, or quality-e2e-tests-5.
- Create a new project
- Run the spec again.
- **Make sure to delete the extra project(s) you created after testing it please
🙏
Note: available_group_path
goes through the groups in order so, if you want to see if it runs it against quality-e2e-tests-3
, you'll need to create a new project for quality-e2e-tests
and quality-e2e-tests-2
.
Edited by Richard Chong