summaryrefslogtreecommitdiff
path: root/spec/models/clusters/applications
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-01-14 00:08:14 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-01-14 00:08:14 +0000
commit427c549b6396885fb60a687326b6cd62878e4ca3 (patch)
tree145713e2f6fdaf7499b0cb44010503e16b6248b9 /spec/models/clusters/applications
parent74a89b1221eaf780374bd1d4c5b2ee4a0f488908 (diff)
downloadgitlab-ce-427c549b6396885fb60a687326b6cd62878e4ca3.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/models/clusters/applications')
-rw-r--r--spec/models/clusters/applications/elastic_stack_spec.rb55
1 files changed, 2 insertions, 53 deletions
diff --git a/spec/models/clusters/applications/elastic_stack_spec.rb b/spec/models/clusters/applications/elastic_stack_spec.rb
index 2179e930691..d336dc752c8 100644
--- a/spec/models/clusters/applications/elastic_stack_spec.rb
+++ b/spec/models/clusters/applications/elastic_stack_spec.rb
@@ -10,45 +10,8 @@ describe Clusters::Applications::ElasticStack do
include_examples 'cluster application version specs', :clusters_applications_elastic_stack
include_examples 'cluster application helm specs', :clusters_applications_elastic_stack
- describe '#can_uninstall?' do
- let(:ingress) { create(:clusters_applications_ingress, :installed, external_hostname: 'localhost.localdomain') }
- let(:elastic_stack) { create(:clusters_applications_elastic_stack, cluster: ingress.cluster) }
-
- subject { elastic_stack.can_uninstall? }
-
- it { is_expected.to be_truthy }
- end
-
- describe '#set_initial_status' do
- before do
- elastic_stack.set_initial_status
- end
-
- context 'when ingress is not installed' do
- let(:cluster) { create(:cluster, :provided_by_gcp) }
- let(:elastic_stack) { create(:clusters_applications_elastic_stack, cluster: cluster) }
-
- it { expect(elastic_stack).to be_not_installable }
- end
-
- context 'when ingress is installed and external_ip is assigned' do
- let(:ingress) { create(:clusters_applications_ingress, :installed, external_ip: '127.0.0.1') }
- let(:elastic_stack) { create(:clusters_applications_elastic_stack, cluster: ingress.cluster) }
-
- it { expect(elastic_stack).to be_installable }
- end
-
- context 'when ingress is installed and external_hostname is assigned' do
- let(:ingress) { create(:clusters_applications_ingress, :installed, external_hostname: 'localhost.localdomain') }
- let(:elastic_stack) { create(:clusters_applications_elastic_stack, cluster: ingress.cluster) }
-
- it { expect(elastic_stack).to be_installable }
- end
- end
-
describe '#install_command' do
- let!(:ingress) { create(:clusters_applications_ingress, :installed, external_ip: '127.0.0.1') }
- let!(:elastic_stack) { create(:clusters_applications_elastic_stack, cluster: ingress.cluster) }
+ let!(:elastic_stack) { create(:clusters_applications_elastic_stack) }
subject { elastic_stack.install_command }
@@ -80,8 +43,7 @@ describe Clusters::Applications::ElasticStack do
end
describe '#uninstall_command' do
- let!(:ingress) { create(:clusters_applications_ingress, :installed, external_ip: '127.0.0.1') }
- let!(:elastic_stack) { create(:clusters_applications_elastic_stack, cluster: ingress.cluster) }
+ let!(:elastic_stack) { create(:clusters_applications_elastic_stack) }
subject { elastic_stack.uninstall_command }
@@ -100,19 +62,6 @@ describe Clusters::Applications::ElasticStack do
end
end
- describe '#files' do
- let!(:ingress) { create(:clusters_applications_ingress, :installed, external_ip: '127.0.0.1') }
- let!(:elastic_stack) { create(:clusters_applications_elastic_stack, cluster: ingress.cluster) }
-
- let(:values) { subject[:'values.yaml'] }
-
- subject { elastic_stack.files }
-
- it 'includes elastic stack specific keys in the values.yaml file' do
- expect(values).to include('ELASTICSEARCH_HOSTS')
- end
- end
-
describe '#elasticsearch_client' do
context 'cluster is nil' do
it 'returns nil' do