Fix order-dependent test when linting audit event factories
Previously if you ran this: ``` FOSS_ONLY=1 bundle exec rspec spec/models/audit_event_spec.rb \ spec/support/shared_examples/lint_factories_shared_examples.rb ``` The shared example file hooks into whatever example groups are loading and attempts to lint them, which is why the audit event model has to run. This would fail with `NameError: uninitialized constant Gitlab::Audit::InstanceScope` because instance-type audit events are only implemented in EE. To avoid this error, only define the `instance_type` trait in EE.
加载中
想要评论请 注册 或 登录