Skip to content

Add QA Feature Flag usage Cop

Dan Davison requested to merge djjr-2759-add-feature-flag-cop into master

What does this MR do and why?

Add a QA Cop that enforces Runtime::Feature usages in end-to-end tests.

Tests that flip or check feature flags will fail in Live environments. This Rubocop will not allow end-to-end tests to interact with Feature Flags unless the :feature_flag RSpec metadata is attached.

This MR also closes the TODO items for this Cop. Two tests made calls to Runtime::Feature without being tagged.

/cc @jroodnick

Closes Fail earlier if a test attempts to flip feature... (gitlab-org/quality/quality-engineering/team-tasks#2759 - 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.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

Edited by Joy Roodnick

Merge request reports