Skip to content
Snippets Groups Projects
Commit ca504a77 authored by Hannes Rosenögger's avatar Hannes Rosenögger Committed by Douwe Maan
Browse files

Fix tests

parent 9bf8480b
Branches
Tags
No related merge requests found
Loading
@@ -20,7 +20,7 @@ describe Projects::FileService do
Loading
@@ -20,7 +20,7 @@ describe Projects::FileService do
it { expect(@link_to_file).to have_key('is_image') } it { expect(@link_to_file).to have_key('is_image') }
it { expect(@link_to_file).to have_value('banana_sample') } it { expect(@link_to_file).to have_value('banana_sample') }
it { expect(@link_to_file['is_image']).to equal(true) } it { expect(@link_to_file['is_image']).to equal(true) }
it { expect(@link_to_file['url']).to match("http://test.example/uploads/#{@project.path_with_namespace}") } it { expect(@link_to_file['url']).to match("/files/#{@project.path_with_namespace}") }
it { expect(@link_to_file['url']).to match('banana_sample.gif') } it { expect(@link_to_file['url']).to match('banana_sample.gif') }
end end
   
Loading
@@ -38,7 +38,7 @@ describe Projects::FileService do
Loading
@@ -38,7 +38,7 @@ describe Projects::FileService do
it { expect(@link_to_file).to have_value('dk') } it { expect(@link_to_file).to have_value('dk') }
it { expect(@link_to_file).to have_key('is_image') } it { expect(@link_to_file).to have_key('is_image') }
it { expect(@link_to_file['is_image']).to equal(true) } it { expect(@link_to_file['is_image']).to equal(true) }
it { expect(@link_to_file['url']).to match("http://test.example/uploads/#{@project.path_with_namespace}") } it { expect(@link_to_file['url']).to match("/files/#{@project.path_with_namespace}") }
it { expect(@link_to_file['url']).to match('dk.png') } it { expect(@link_to_file['url']).to match('dk.png') }
end end
   
Loading
@@ -53,7 +53,7 @@ describe Projects::FileService do
Loading
@@ -53,7 +53,7 @@ describe Projects::FileService do
it { expect(@link_to_file).to have_key('is_image') } it { expect(@link_to_file).to have_key('is_image') }
it { expect(@link_to_file).to have_value('rails_sample') } it { expect(@link_to_file).to have_value('rails_sample') }
it { expect(@link_to_file['is_image']).to equal(true) } it { expect(@link_to_file['is_image']).to equal(true) }
it { expect(@link_to_file['url']).to match("http://test.example/uploads/#{@project.path_with_namespace}") } it { expect(@link_to_file['url']).to match("/files/#{@project.path_with_namespace}") }
it { expect(@link_to_file['url']).to match('rails_sample.jpg') } it { expect(@link_to_file['url']).to match('rails_sample.jpg') }
end end
   
Loading
@@ -70,7 +70,7 @@ describe Projects::FileService do
Loading
@@ -70,7 +70,7 @@ describe Projects::FileService do
it { expect(@link_to_file).to have_key('is_image') } it { expect(@link_to_file).to have_key('is_image') }
it { expect(@link_to_file).to have_value('doc_sample.txt') } it { expect(@link_to_file).to have_value('doc_sample.txt') }
it { expect(@link_to_file['is_image']).to equal(false) } it { expect(@link_to_file['is_image']).to equal(false) }
it { expect(@link_to_file['url']).to match("http://test.example/uploads/#{@project.path_with_namespace}") } it { expect(@link_to_file['url']).to match("/files/#{@project.path_with_namespace}") }
it { expect(@link_to_file['url']).to match('doc_sample.txt') } it { expect(@link_to_file['url']).to match('doc_sample.txt') }
end end
end end
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment