Skip to content

Commit 1450161

Browse files
committed
Merge pull request #29 from ActiveTriples/rspec-style
Avoid the deprecated rspec 'should' syntax
2 parents 921a221 + c86b591 commit 1450161

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

spec/caching/blazegraph_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
RSpec.describe LinkedDataFragments::Blazegraph do
44
subject {
5-
Setting.stub(:cache_backend).and_return('blazegraph')
6-
Setting.stub(:cache_backend_url).and_return('http://localhost:8988/blazegraph/sparql')
7-
Setting.stub(:cache_backend_context).and_return('http://localhost:8988/linked-data-fragments-test')
5+
allow(Setting).to receive(:cache_backend).and_return('blazegraph')
6+
allow(Setting).to receive(:cache_backend_url).and_return('http://localhost:8988/blazegraph/sparql')
7+
allow(Setting).to receive(:cache_backend_context).and_return('http://localhost:8988/linked-data-fragments-test')
88
LinkedDataFragments::Blazegraph.new
99
}
1010

spec/caching/marmotta_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
RSpec.describe LinkedDataFragments::Marmotta do
44
subject {
5-
Setting.stub(:cache_backend).and_return('marmotta')
6-
Setting.stub(:cache_backend_url).and_return('http://localhost:8988/marmotta')
7-
Setting.stub(:cache_backend_context).and_return('http://localhost:8988/linked-data-fragments-test')
5+
allow(Setting).to receive(:cache_backend).and_return('marmotta')
6+
allow(Setting).to receive(:cache_backend_url).and_return('http://localhost:8988/marmotta')
7+
allow(Setting).to receive(:cache_backend_context).and_return('http://localhost:8988/linked-data-fragments-test')
88
LinkedDataFragments::Marmotta.new
99
}
1010

spec/caching/repository_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
RSpec.describe LinkedDataFragments::Repository do
44
subject {
5-
Setting.stub(:cache_backend).and_return('repository')
5+
allow(Setting).to receive(:cache_backend).and_return('repository')
66
LinkedDataFragments::Repository.new
77
}
88

spec/spec_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
end
4444

4545
config.before(:each) do
46-
Setting.stub(:cache_backend).and_return('repository')
46+
allow(Setting).to receive(:cache_backend).and_return('repository')
4747
end
4848

4949
# The settings below are suggested to provide a good initial experience

0 commit comments

Comments
 (0)