Commit e61cbe7f authored by Robert Speicher's avatar Robert Speicher

Merge branch...

Merge branch 'ee-6516-extract-ee-specific-files-lines-for-spec-models-project_services' into 'master'

Tweak kubernetes_service_spec for EE compatibility

Closes gitlab-ee#6516

See merge request gitlab-org/gitlab-ce!26155
parents 65bbfd5a dd673660
...@@ -360,14 +360,16 @@ describe KubernetesService, :use_clean_rails_memory_store_caching do ...@@ -360,14 +360,16 @@ describe KubernetesService, :use_clean_rails_memory_store_caching do
context 'when kubernetes responds with valid pods' do context 'when kubernetes responds with valid pods' do
before do before do
stub_kubeclient_pods stub_kubeclient_pods
stub_kubeclient_deployments # Used by EE
end end
it { is_expected.to eq(pods: [kube_pod]) } it { is_expected.to include(pods: [kube_pod]) }
end end
context 'when kubernetes responds with 500s' do context 'when kubernetes responds with 500s' do
before do before do
stub_kubeclient_pods(status: 500) stub_kubeclient_pods(status: 500)
stub_kubeclient_deployments(status: 500) # Used by EE
end end
it { expect { subject }.to raise_error(Kubeclient::HttpError) } it { expect { subject }.to raise_error(Kubeclient::HttpError) }
...@@ -376,9 +378,10 @@ describe KubernetesService, :use_clean_rails_memory_store_caching do ...@@ -376,9 +378,10 @@ describe KubernetesService, :use_clean_rails_memory_store_caching do
context 'when kubernetes responds with 404s' do context 'when kubernetes responds with 404s' do
before do before do
stub_kubeclient_pods(status: 404) stub_kubeclient_pods(status: 404)
stub_kubeclient_deployments(status: 404) # Used by EE
end end
it { is_expected.to eq(pods: []) } it { is_expected.to include(pods: []) }
end end
end end
......
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