diff options
Diffstat (limited to 'spec/support')
-rw-r--r-- | spec/support/shared_examples/uploaders/gitlab_uploader_shared_examples.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/support/shared_examples/uploaders/gitlab_uploader_shared_examples.rb b/spec/support/shared_examples/uploaders/gitlab_uploader_shared_examples.rb index 93c21a99e59..1190863d88e 100644 --- a/spec/support/shared_examples/uploaders/gitlab_uploader_shared_examples.rb +++ b/spec/support/shared_examples/uploaders/gitlab_uploader_shared_examples.rb @@ -33,6 +33,14 @@ shared_examples "builds correct paths" do |**patterns| it_behaves_like "matches the method pattern", :upload_path end + describe "#relative_path" do + it 'is relative' do + skip 'Path not set, skipping.' unless subject.path + + expect(Pathname.new(subject.relative_path)).to be_relative + end + end + describe ".absolute_path" do it_behaves_like "matches the method pattern", :absolute_path do let(:target) { subject.class } |