Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2017-07-03 22:35:06 +0300
committerLin Jen-Shin <godfat@godfat.org>2017-07-04 13:18:36 +0300
commit84e37683cb838337f84df387ec8e8251e167fa20 (patch)
tree16f081cdb3f59c070e9fa764ba5bc706d2404608 /spec
parent4d9c2bad369d510877dff719d94a5f98b1ee4dfe (diff)
Make sure we remove null characters
Diffstat (limited to 'spec')
-rw-r--r--spec/models/project_spec.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/models/project_spec.rb b/spec/models/project_spec.rb
index f06f7d6b54b..4ef768123bd 100644
--- a/spec/models/project_spec.rb
+++ b/spec/models/project_spec.rb
@@ -1532,8 +1532,8 @@ describe Project, models: true do
expect(project.ci_config_file).to eq('foo/.gitlab_ci.yml')
end
- it 'sets a string but remove all leading slashes' do
- project.update!(ci_config_file: '///foo//.gitlab_ci.yml')
+ it 'sets a string but remove all leading slashes and null characters' do
+ project.update!(ci_config_file: "///f\0oo/\0/.gitlab_ci.yml")
expect(project.ci_config_file).to eq('foo//.gitlab_ci.yml')
end