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
diff options
context:
space:
mode:
Diffstat (limited to 'spec/lib/gitlab/blob_helper_spec.rb')
-rw-r--r--spec/lib/gitlab/blob_helper_spec.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/spec/lib/gitlab/blob_helper_spec.rb b/spec/lib/gitlab/blob_helper_spec.rb
index e18277ba8d2..6d1e6ea59a3 100644
--- a/spec/lib/gitlab/blob_helper_spec.rb
+++ b/spec/lib/gitlab/blob_helper_spec.rb
@@ -7,6 +7,7 @@ RSpec.describe Gitlab::BlobHelper do
let(:project) { create(:project) }
let(:blob) { fake_blob(path: 'file.txt') }
+ let(:bmp_blob) { fake_blob(path: 'file.bmp') }
let(:webp_blob) { fake_blob(path: 'file.webp') }
let(:large_blob) { fake_blob(path: 'test.pdf', size: 2.megabytes, binary: true) }
@@ -69,6 +70,12 @@ RSpec.describe Gitlab::BlobHelper do
end
end
+ context 'with a .bmp file' do
+ it 'returns true' do
+ expect(bmp_blob.image?).to be_truthy
+ end
+ end
+
context 'with a .webp file' do
it 'returns true' do
expect(webp_blob.image?).to be_truthy