Commit d11a55e7 authored by Andy Soiron's avatar Andy Soiron

Merge branch '233819_refactor_rename' into 'master'

Rename Kubernetes error entity to be more specific

See merge request gitlab-org/gitlab!79150
parents 505eb780 e47671aa
......@@ -496,7 +496,6 @@ Gitlab/NamespacedClass:
- app/serializers/build_trace_serializer.rb
- app/serializers/cluster_application_entity.rb
- app/serializers/cluster_entity.rb
- app/serializers/cluster_error_entity.rb
- app/serializers/cluster_serializer.rb
- app/serializers/codequality_degradation_entity.rb
- app/serializers/codequality_reports_comparer_entity.rb
......
......@@ -24,7 +24,7 @@ class ClusterEntity < Grape::Entity
end
expose :kubernetes_errors do |cluster|
ClusterErrorEntity.new(cluster)
Clusters::KubernetesErrorEntity.new(cluster)
end
expose :enable_advanced_logs_querying do |cluster|
......
# frozen_string_literal: true
class ClusterErrorEntity < Grape::Entity
expose :connection_error
expose :metrics_connection_error
expose :node_connection_error
end
# frozen_string_literal: true
module Clusters
class KubernetesErrorEntity < Grape::Entity
expose :connection_error
expose :metrics_connection_error
expose :node_connection_error
end
end
......@@ -2,7 +2,7 @@
require 'spec_helper'
RSpec.describe ClusterErrorEntity do
RSpec.describe Clusters::KubernetesErrorEntity do
describe '#as_json' do
let(:cluster) { create(:cluster, :provided_by_user, :group) }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment