Skip to content

E2E: Split SSH support into individual spec files

John McDonnell requested to merge jmd/e2e-cleanup-ssh-key-after-create into master

What does this MR do and why?

Part of Add SSH keys to resource cleanup (gitlab-org/quality/quality-engineering/team-tasks#2843)

There's 2 parts to this MR,

  1. Splitting tests in unique spec files. Prior to E2E test: make add and delete ssh key spec idem... (!142101 - merged) the two tests here shared the same SSH key, so it made sense that the specs would be in the same spec file. However as the tests are now idempotent there's no good reason to keep them together.

  2. Adds post test hook to remove SSH key created by test. We should ensure that we delete the SSH keys we add to our live test environments to avoid them growing in number. Having too many SSH keys in a single account can make the page slow to load which in turn can make the spec flaky.

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

$ bundle exec rspec qa/specs/features/browser_ui/3_create/repository/ssh_key_support_create_spec.rb qa/specs/features/browser_ui/3_create/repository/ssh_key_support_delete_spec.rb

Merge request reports