BigW Consortium Gitlab

Commit 84e37683 by Lin Jen-Shin

Make sure we remove null characters

parent 4d9c2bad
......@@ -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
......
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