summaryrefslogtreecommitdiff
path: root/spec/uploaders
diff options
context:
space:
mode:
authorTakuya Noguchi <takninnovationresearch@gmail.com>2018-01-27 14:35:53 +0900
committerTakuya Noguchi <takninnovationresearch@gmail.com>2018-02-01 02:06:07 +0900
commit2b6307f6ad9d09156c42befe4babbfea40dad052 (patch)
tree2a05eb3e7a481ed803ea62a2d4e7667baff44375 /spec/uploaders
parent08e013431acb5238b4806260c4b9c304837097a3 (diff)
downloadgitlab-ce-2b6307f6ad9d09156c42befe4babbfea40dad052.tar.gz
Enable RuboCop Style/RegexpLiteral
Diffstat (limited to 'spec/uploaders')
-rw-r--r--spec/uploaders/file_uploader_spec.rb2
-rw-r--r--spec/uploaders/job_artifact_uploader_spec.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/spec/uploaders/file_uploader_spec.rb b/spec/uploaders/file_uploader_spec.rb
index fd195d6f9b8..845516e5004 100644
--- a/spec/uploaders/file_uploader_spec.rb
+++ b/spec/uploaders/file_uploader_spec.rb
@@ -112,7 +112,7 @@ describe FileUploader do
fixture = Rails.root.join('spec', 'fixtures', 'rails_sample.jpg')
uploader.store!(fixture_file_upload(fixture))
- expect(uploader.relative_path).to match(/\A\h{32}\/rails_sample.jpg\z/)
+ expect(uploader.relative_path).to match(%r{\A\h{32}/rails_sample.jpg\z})
end
end
end
diff --git a/spec/uploaders/job_artifact_uploader_spec.rb b/spec/uploaders/job_artifact_uploader_spec.rb
index 98a4373e9d0..a067c3e75f4 100644
--- a/spec/uploaders/job_artifact_uploader_spec.rb
+++ b/spec/uploaders/job_artifact_uploader_spec.rb
@@ -12,7 +12,7 @@ describe JobArtifactUploader do
context 'when using local storage' do
it { is_expected.to start_with(local_path) }
- it { is_expected.to match(/\h{2}\/\h{2}\/\h{64}\/\d{4}_\d{1,2}_\d{1,2}\/\d+\/\d+\z/) }
+ it { is_expected.to match(%r{\h{2}/\h{2}/\h{64}/\d{4}_\d{1,2}_\d{1,2}/\d+/\d+\z}) }
it { is_expected.to end_with(path) }
end
end