Skip to content
This repository was archived by the owner on Apr 16, 2024. It is now read-only.

Commit 8db9f43

Browse files
author
Arfon Smith
committed
Fixing some specs
1 parent eacd8d6 commit 8db9f43

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

fixtures/paper/crossref-metadata.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
timestamp: '20200228090040'
3-
doi_batch_id: 4004ce6db4577d4cd5153c8f16ba1c37
2+
timestamp: '20201102125108'
3+
doi_batch_id: 284d9bf1426ea0f102dbc700e62c180e
44
formatted_doi: 10.21105/joss.00017
55
archive_doi: '"http://dx.doi.org/10.5281/zenodo.13750"'
66
review_issue_url: https://github.com/openjournals/joss-reviews/issues/17
@@ -14,7 +14,7 @@ journal_issn: 2475-9066
1414
month: 5
1515
day: 11
1616
year: 2016
17-
issue: -44
17+
issue: -53
1818
volume: -3
1919
page: 17
2020
title: 'Fidgit: An ungodly union of GitHub and figshare'

spec/processor_spec.rb

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
require 'nokogiri'
33

44
describe Whedon::Processor do
5-
subject(:paper) { Whedon::Paper.new(17, 'fixtures/paper/paper.md') }
6-
subject(:paper_with_funky_bib_path) { Whedon::Paper.new(17, 'fixtures/paper/paper-bib.md') }
5+
subject(:paper) { Whedon::Paper.new(17, nil, 'fixtures/paper/paper.md') }
6+
subject(:paper_with_funky_bib_path) { Whedon::Paper.new(17, nil, 'fixtures/paper/paper-bib.md') }
77

88
subject(:processor) { Whedon::Processor.new(17, File.read('fixtures/review_body.txt')) }
99

spec/whedon_spec.rb

+5-5
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
describe Whedon do
44

5-
subject(:paper) { Whedon::Paper.new(17, 'fixtures/paper/paper.md') }
6-
subject(:paper_with_one_author) { Whedon::Paper.new(17, 'fixtures/paper/paper-single-author.md') }
7-
subject(:paper_with_harder_names) { Whedon::Paper.new(17, 'fixtures/paper/paper-with-harder-names.md') }
5+
subject(:paper) { Whedon::Paper.new(17, nil, 'fixtures/paper/paper.md') }
6+
subject(:paper_with_one_author) { Whedon::Paper.new(17, nil, 'fixtures/paper/paper-single-author.md') }
7+
subject(:paper_with_harder_names) { Whedon::Paper.new(17, nil, 'fixtures/paper/paper-with-harder-names.md') }
88

99
it "should initialize properly" do
1010
expect(paper.review_issue_id).to eql(17)
@@ -76,11 +76,11 @@
7676
end
7777

7878
it "should fail to initialize when authors don't have affiliations" do
79-
expect { Whedon::Paper.new(17, 'fixtures/paper/paper-with-missing-affiliations.md') }.to raise_error("Author (Arfon M Smith) is missing affiliation")
79+
expect { Whedon::Paper.new(17, nil, 'fixtures/paper/paper-with-missing-affiliations.md') }.to raise_error("Author (Arfon M Smith) is missing affiliation")
8080
end
8181

8282
it "should fail to initialize when title is missing" do
83-
expect { Whedon::Paper.new(17, 'fixtures/paper/paper_with_missing_title.md') }.to raise_error(/Paper YAML header is missing expected fields: title/)
83+
expect { Whedon::Paper.new(17, nil, 'fixtures/paper/paper_with_missing_title.md') }.to raise_error(/Paper YAML header is missing expected fields: title/)
8484
end
8585

8686
it "should know how to generate the deposit_payload" do

0 commit comments

Comments
 (0)