Skip Migration/EnsureFactoryForTable in CE
What does this MR do and why?
Since migrations for EE models don't have factories in CE we need to skip this cop in foss-only CI.
This commit also simplifies the implementation and improves the performances be caching files operations.
Refs gitlab-org/quality/engineering-productivity/master-broken-incidents#5671 (comment 1843375444).
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 rubocop -C false --only Migration/EnsureFactoryForTable db/migrate
602 files inspected, no offenses detected
# FOSS only
mv ee ee-off
bundle exec rubocop -C false --only Migration/EnsureFactoryForTable db/migrate
602 files inspected, no offenses detected
bundle exec rake rubocop:todo:generate[Migration/EnsureFactoryForTable]
# No changes
Edited by Peter Leitzen