Skip to content

Commit

Permalink
Implements Helge's recommendations
Browse files Browse the repository at this point in the history
  • Loading branch information
philippbayer committed Feb 12, 2016
1 parent b7ec351 commit 45f172b
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 12 deletions.
8 changes: 1 addition & 7 deletions spec/integration/plos_details_spec.rb
Expand Up @@ -4,15 +4,9 @@
let(:plos_paper) do
create(:plos_paper, id: 1, reader: 0, doi: '10.1371/journal.pone.0089204')
end
let(:job) {PlosDetails.new}

it 'updates the view count' do
before = plos_paper.reader

VCR.use_cassette 'plos_detail' do
job.perform plos_paper.id
end
expect(plos_paper.reload.reader).not_to eq(before)
subject.perform plos_paper.id
expect(plos_paper.reload.reader).to eq(5047) # that's a lot of openSNP readers!
end
end
1 change: 1 addition & 0 deletions spec/support/vcr_setup.rb
@@ -1,4 +1,5 @@
VCR.configure do |c|
c.cassette_library_dir = 'spec/vcr'
c.hook_into :webmock
c.configure_rspec_metadata!
end

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 45f172b

Please sign in to comment.