Extract EE specific files/lines for spec/support/shared_contexts
We have the following files containing EE specific code. We should move them to ee/
spec/support/shared_contexts/services_shared_context.rb
diff --git a/spec/support/shared_contexts/services_shared_context.rb b/home/yorickpeterse/Projects/gitlab/gdk-ee/gitlab/spec/support/shared_contexts/services_shared_context.rb
index d92e8318fa0..83b16fea7b1 100644
--- a/spec/support/shared_contexts/services_shared_context.rb
+++ b/home/yorickpeterse/Projects/gitlab/gdk-ee/gitlab/spec/support/shared_contexts/services_shared_context.rb
@@ -26,6 +26,14 @@ Service.available_services_names.each do |service|
end
end
+ before do
+ if service == 'github'
+ stub_licensed_features(github_project_service_integration: true)
+ project.clear_memoization(:disabled_services)
+ project.clear_memoization(:licensed_feature_available)
+ end
+ end
+
def initialize_service(service)
service_item = project.find_or_initialize_service(service)
service_item.properties = service_attrs
Edited by Yorick Peterse