summaryrefslogtreecommitdiff
path: root/spec/models/clusters
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-10-23 18:06:07 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2019-10-23 18:06:07 +0000
commit7f0a4a64d0bc59b184ae3ee578adb6ebd3c48bf7 (patch)
tree74aa541f76b8d7cd692982ce46c0013a9b666172 /spec/models/clusters
parentb3f7042d06c53e5d4b8cad42e1b2679d0450f1a7 (diff)
downloadgitlab-ce-7f0a4a64d0bc59b184ae3ee578adb6ebd3c48bf7.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/models/clusters')
-rw-r--r--spec/models/clusters/applications/ingress_spec.rb18
1 files changed, 18 insertions, 0 deletions
diff --git a/spec/models/clusters/applications/ingress_spec.rb b/spec/models/clusters/applications/ingress_spec.rb
index 9806b49d7a6..60b139a7610 100644
--- a/spec/models/clusters/applications/ingress_spec.rb
+++ b/spec/models/clusters/applications/ingress_spec.rb
@@ -156,6 +156,15 @@ describe Clusters::Applications::Ingress do
it 'includes modsecurity core ruleset enablement' do
expect(subject.values).to include("enable-owasp-modsecurity-crs: 'true'")
end
+
+ it 'includes modsecurity.conf content' do
+ expect(subject.values).to include('modsecurity.conf')
+ # Includes file content from Ingress#modsecurity_config_content
+ expect(subject.values).to include('SecAuditLog')
+
+ expect(subject.values).to include('extraVolumes')
+ expect(subject.values).to include('extraVolumeMounts')
+ end
end
context 'when ingress_modsecurity is disabled' do
@@ -172,6 +181,15 @@ describe Clusters::Applications::Ingress do
it 'excludes modsecurity core ruleset enablement' do
expect(subject.values).not_to include('enable-owasp-modsecurity-crs')
end
+
+ it 'excludes modsecurity.conf content' do
+ expect(subject.values).not_to include('modsecurity.conf')
+ # Excludes file content from Ingress#modsecurity_config_content
+ expect(subject.values).not_to include('SecAuditLog')
+
+ expect(subject.values).not_to include('extraVolumes')
+ expect(subject.values).not_to include('extraVolumeMounts')
+ end
end
end
end