commonmeta-ruby 3.8.1 → 3.8.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ae080d03483347a1467f664fa167e5e2103315cbccd60713743dbe73e9499824
4
- data.tar.gz: 991d47e1e3bfa424b4660e921d9ab035f960c8e28c96ffbf4e30ab931d3eff46
3
+ metadata.gz: f92c91c3ea4495bb052b4c316d146566a9bf0c784e2edf55134f4ebef50156a9
4
+ data.tar.gz: 6b70e63796e13193ae0782775700498588bd289ad086e266e05b0eba90bc29a3
5
5
  SHA512:
6
- metadata.gz: 675c0176e21eb08f844c7c95ced271a88a5eb870f9f962b1edf9a4d29b064812d951416b5fd5bf00089e4cfbf10ad6d6d67794241251b7a86e2ac4247397aae0
7
- data.tar.gz: ab0ab117a6c0dc7103d23b84e4fadd8f6f99b6193553fc0435a174c20656c241a4c6d79b70933c0d3644bff959995dde35ed16ca2609b8d4f88b2e643baeb3be
6
+ metadata.gz: d526121e057c30beec3568834cb972e6f870f1d681f1a37d223aa4b79a5bfb5943a79bbd699c50512ae0ad6c90313e392f4e1b1fc1e07f4181015228dfcacb3a
7
+ data.tar.gz: a7646d597a54a2e8e5f02af0650eccb80695d2e6706e346b756fbbd591bcdb1bf13e530c2ffbd8a55d39bae7dbf173a9c1f8f8489546bcf01dd6a6b99994d15f
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- commonmeta-ruby (3.8.1)
4
+ commonmeta-ruby (3.8.3)
5
5
  activesupport (>= 4.2.5, < 8.0)
6
6
  addressable (~> 2.8.1, < 2.8.2)
7
7
  base32-url (>= 0.7.0, < 1)
@@ -348,8 +348,10 @@ module Commonmeta
348
348
  xml.collection("property" => "text-mining") do
349
349
  xml.item do
350
350
  xml.resource(url, "mime_type" => "text/html")
351
- if is_rogue_scholar_doi?(doi)
352
- Array.wrap(files).each do |file|
351
+ end
352
+ if is_rogue_scholar_doi?(doi)
353
+ Array.wrap(files).each do |file|
354
+ xml.item do
353
355
  # Crossref schema currently doesn't support text/markdown
354
356
  file["mimeType"] = "text/plain" if file["mimeType"] == "text/markdown"
355
357
  xml.resource(file["url"], "mime_type" => file["mimeType"])
@@ -110,7 +110,8 @@ module Commonmeta
110
110
 
111
111
  [{ "mimeType" => "text/markdown", "url" => "https://api.rogue-scholar.org/posts/#{doi}.md" },
112
112
  { "mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/#{doi}.pdf" },
113
- { "mimeType" => "application/epub+zip", "url" => "https://api.rogue-scholar.org/posts/#{doi}.epub" }]
113
+ { "mimeType" => "application/epub+zip", "url" => "https://api.rogue-scholar.org/posts/#{doi}.epub" },
114
+ { "mimeType" => "application/xml", "url" => "https://api.rogue-scholar.org/posts/#{doi}.xml" }]
114
115
  end
115
116
 
116
117
  def get_references(meta)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Commonmeta
4
- VERSION = '3.8.1'
4
+ VERSION = '3.8.3'
5
5
  end
@@ -36,7 +36,7 @@ describe Commonmeta::Metadata, vcr: true do
36
36
  # expect(subject.valid?).to be true
37
37
  expect(subject.id).to eq("https://doi.org/10.53731/4nwxn-frt36")
38
38
  expect(subject.url).to eq("https://blog.front-matter.io/posts/does-it-compose")
39
- expect(subject.files.length).to eq(3)
39
+ expect(subject.files.length).to eq(4)
40
40
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.53731/4nwxn-frt36.pdf")
41
41
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "5bb66e92-5cb9-4659-8aca-20e486b695c9", "alternateIdentifierType" => "UUID" }])
42
42
  expect(subject.type).to eq("Article")
@@ -62,7 +62,7 @@ describe Commonmeta::Metadata, vcr: true do
62
62
  # expect(subject.valid?).to be true
63
63
  expect(subject.id).to eq("https://doi.org/10.53731/r79v4e1-97aq74v-ag578")
64
64
  expect(subject.url).to eq("https://blog.front-matter.io/posts/differences-between-orcid-and-datacite-metadata")
65
- expect(subject.files.length).to eq(3)
65
+ expect(subject.files.length).to eq(4)
66
66
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.53731/r79v4e1-97aq74v-ag578.pdf")
67
67
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "8a4de443-3347-4b82-b57d-e3c82b6485fc", "alternateIdentifierType" => "UUID" }])
68
68
  expect(subject.type).to eq("Article")
@@ -89,7 +89,7 @@ describe Commonmeta::Metadata, vcr: true do
89
89
  # expect(subject.valid?).to be true
90
90
  expect(subject.id).to eq("https://doi.org/10.53731/r294649-6f79289-8cw18")
91
91
  expect(subject.url).to eq("https://blog.front-matter.io/posts/nine-simple-ways-to-make-it-easier-to-re-use-your-data")
92
- expect(subject.files.length).to eq(3)
92
+ expect(subject.files.length).to eq(4)
93
93
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.53731/r294649-6f79289-8cw18.pdf")
94
94
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "2bdebfc5-e02e-42c2-90c5-e873e2d0435d", "alternateIdentifierType" => "UUID" }])
95
95
  expect(subject.type).to eq("Article")
@@ -116,7 +116,7 @@ describe Commonmeta::Metadata, vcr: true do
116
116
  # expect(subject.valid?).to be true
117
117
  expect(subject.id).to eq("https://doi.org/10.53731/r79s4nh-97aq74v-ag4t1")
118
118
  expect(subject.url).to eq("https://blog.front-matter.io/posts/tracking-the-growth-of-the-pid-graph")
119
- expect(subject.files.length).to eq(3)
119
+ expect(subject.files.length).to eq(4)
120
120
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.53731/r79s4nh-97aq74v-ag4t1.pdf")
121
121
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "e58dc9c8-b870-4db2-8896-238b3246c551", "alternateIdentifierType" => "UUID" }])
122
122
  expect(subject.type).to eq("Article")
@@ -195,7 +195,7 @@ describe Commonmeta::Metadata, vcr: true do
195
195
  # expect(subject.valid?).to be true
196
196
  expect(subject.id).to eq("https://doi.org/10.53731/ffbx660-083tnag")
197
197
  expect(subject.url).to eq("https://syldavia-gazette.org/guinea-worms-chatgpt-neanderthals")
198
- expect(subject.files.length).to eq(3)
198
+ expect(subject.files.length).to eq(4)
199
199
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.53731/ffbx660-083tnag.pdf")
200
200
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "0022b9ef-525a-4a79-81ad-13411697f58a", "alternateIdentifierType" => "UUID" }])
201
201
  expect(subject.type).to eq("Article")
@@ -220,7 +220,7 @@ describe Commonmeta::Metadata, vcr: true do
220
220
  # expect(subject.valid?).to be true
221
221
  expect(subject.id).to eq("https://doi.org/10.59350/kz04m-s8z58")
222
222
  expect(subject.url).to eq("https://wisspub.net/2023/05/23/eu-mitgliedstaaten-betonen-die-rolle-von-wissenschaftsgeleiteten-open-access-modellen-jenseits-von-apcs")
223
- expect(subject.files.length).to eq(3)
223
+ expect(subject.files.length).to eq(4)
224
224
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/kz04m-s8z58.pdf")
225
225
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "1c578558-1324-4493-b8af-84c49eabc52f", "alternateIdentifierType" => "UUID" }])
226
226
  expect(subject.type).to eq("Article")
@@ -246,7 +246,7 @@ describe Commonmeta::Metadata, vcr: true do
246
246
  # expect(subject.valid?).to be true
247
247
  expect(subject.id).to eq("https://doi.org/10.59350/faeph-x4x84")
248
248
  expect(subject.url).to eq("https://wayback.archive-it.org/22143/20231103191454/https://project-thor.eu/2016/08/10/orcid-integration-in-pangaea")
249
- expect(subject.files.length).to eq(3)
249
+ expect(subject.files.length).to eq(4)
250
250
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/faeph-x4x84.pdf")
251
251
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "570c8129-e867-49e6-8517-bd783627e76e", "alternateIdentifierType" => "UUID" }])
252
252
  expect(subject.type).to eq("Article")
@@ -278,7 +278,7 @@ describe Commonmeta::Metadata, vcr: true do
278
278
  # expect(subject.valid?).to be true
279
279
  expect(subject.id).to eq("https://doi.org/10.59350/hke8v-d1e66")
280
280
  expect(subject.url).to eq("https://svpow.com/2023/06/09/new-paper-curtice-et-al-2023-on-the-first-haplocanthosaurus-from-dry-mesa")
281
- expect(subject.files.length).to eq(3)
281
+ expect(subject.files.length).to eq(4)
282
282
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/hke8v-d1e66.pdf")
283
283
  expect(subject.type).to eq("Article")
284
284
  expect(subject.contributors.length).to eq(1)
@@ -305,7 +305,7 @@ describe Commonmeta::Metadata, vcr: true do
305
305
  # expect(subject.valid?).to be true
306
306
  expect(subject.id).to eq("https://doi.org/10.59350/tpa8t-j6292")
307
307
  expect(subject.url).to eq("https://www.samuelmoore.org/2023/04/20/how-to-cultivate-good-closures-scaling-small-and-the-limits-of-openness")
308
- expect(subject.files.length).to eq(3)
308
+ expect(subject.files.length).to eq(4)
309
309
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/tpa8t-j6292.pdf")
310
310
  expect(subject.type).to eq("Article")
311
311
  expect(subject.contributors.length).to eq(1)
@@ -331,7 +331,7 @@ describe Commonmeta::Metadata, vcr: true do
331
331
  # expect(subject.valid?).to be true
332
332
  expect(subject.id).to eq("https://doi.org/10.59350/tfahc-rp566")
333
333
  expect(subject.url).to eq("https://blog.oa.works/nature-features-oa-reports-work-putting-oa-policy-into-practice")
334
- expect(subject.files.length).to eq(3)
334
+ expect(subject.files.length).to eq(4)
335
335
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/tfahc-rp566.pdf")
336
336
  expect(subject.type).to eq("Article")
337
337
  expect(subject.contributors.length).to eq(1)
@@ -382,7 +382,7 @@ describe Commonmeta::Metadata, vcr: true do
382
382
  # expect(subject.valid?).to be true
383
383
  expect(subject.id).to eq("https://doi.org/10.59350/zwdq7-waa43")
384
384
  expect(subject.url).to eq("https://citationstyles.org/2020/07/11/seeking-public-comment-on-CSL-1-0-2")
385
- expect(subject.files.length).to eq(3)
385
+ expect(subject.files.length).to eq(4)
386
386
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/zwdq7-waa43.pdf")
387
387
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "efdacb04-bcec-49d7-b689-ab3eab0634bf", "alternateIdentifierType" => "UUID" }])
388
388
  expect(subject.type).to eq("Article")
@@ -409,7 +409,7 @@ describe Commonmeta::Metadata, vcr: true do
409
409
  # expect(subject.valid?).to be true
410
410
  expect(subject.id).to eq("https://doi.org/10.59350/2shz7-ehx26")
411
411
  expect(subject.url).to eq("https://libscie.org/ku-leuven-supports-researchequals")
412
- expect(subject.files.length).to eq(3)
412
+ expect(subject.files.length).to eq(4)
413
413
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/2shz7-ehx26.pdf")
414
414
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "5561f8e4-2ff1-4186-a8d5-8dacb3afe414", "alternateIdentifierType" => "UUID" }])
415
415
  expect(subject.type).to eq("Article")
@@ -436,7 +436,7 @@ describe Commonmeta::Metadata, vcr: true do
436
436
  # expect(subject.valid?).to be true
437
437
  expect(subject.id).to eq("https://doi.org/10.59350/33es7-fqz31")
438
438
  expect(subject.url).to eq("https://lab.sub.uni-goettingen.de/welcome.html")
439
- expect(subject.files.length).to eq(3)
439
+ expect(subject.files.length).to eq(4)
440
440
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/33es7-fqz31.pdf")
441
441
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "a163e340-5b3c-4736-9ab0-8c54fdff6a3c", "alternateIdentifierType" => "UUID" }])
442
442
  expect(subject.type).to eq("Article")
@@ -463,7 +463,7 @@ describe Commonmeta::Metadata, vcr: true do
463
463
  # expect(subject.valid?).to be true
464
464
  expect(subject.id).to eq("https://doi.org/10.59350/63055-a8604")
465
465
  expect(subject.url).to eq("http://sfmatheson.blogspot.com/2023/01/quintessence-of-dust-2023-restart-why.html")
466
- expect(subject.files.length).to eq(3)
466
+ expect(subject.files.length).to eq(4)
467
467
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/63055-a8604.pdf")
468
468
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "1898d2d7-4d87-4487-96c4-3073cf99e9a5", "alternateIdentifierType" => "UUID" }])
469
469
  expect(subject.type).to eq("Article")
@@ -490,7 +490,7 @@ describe Commonmeta::Metadata, vcr: true do
490
490
  # expect(subject.valid?).to be true
491
491
  expect(subject.id).to eq("https://doi.org/10.59350/9gfjs-pey70")
492
492
  expect(subject.url).to eq("https://flavoursofopen.science/grundlagen-fur-die-entwicklung-einer-open-scholarship-strategie")
493
- expect(subject.files.length).to eq(3)
493
+ expect(subject.files.length).to eq(4)
494
494
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/9gfjs-pey70.pdf")
495
495
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "f3dc29da-0481-4f3b-8110-4c07260fca67", "alternateIdentifierType" => "UUID" }])
496
496
  expect(subject.type).to eq("Article")
@@ -518,7 +518,7 @@ describe Commonmeta::Metadata, vcr: true do
518
518
  # expect(subject.valid?).to be true
519
519
  expect(subject.id).to eq("https://doi.org/10.59350/bbcsr-r4b59")
520
520
  expect(subject.url).to eq("https://markrubin.substack.com/p/the-preregistration-prescriptiveness")
521
- expect(subject.files.length).to eq(3)
521
+ expect(subject.files.length).to eq(4)
522
522
  expect(subject.files[1]).to eq("mimeType" => "application/pdf", "url" => "https://api.rogue-scholar.org/posts/10.59350/bbcsr-r4b59.pdf")
523
523
  expect(subject.alternate_identifiers).to eq([{ "alternateIdentifier" => "2b105b29-acbc-4eae-9ff1-368803f36a4d", "alternateIdentifierType" => "UUID" }])
524
524
  expect(subject.type).to eq("Article")
@@ -232,9 +232,8 @@ describe Commonmeta::Metadata, vcr: true do
232
232
  "title")).to eq("Attempts at automating journal subject classification")
233
233
  expect(crossref_xml.dig("item_number")).to eq("__content__" => "5d14ffacb9ac4e20bdc0d9248df4e80d", "item_number_type" => "uuid")
234
234
  expect(crossref_xml.dig("group_title")).to eq("Humanities")
235
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource").length).to eq(4)
236
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource", 2)).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.54900/n6dnt-xpq48.pdf", "mime_type" => "application/pdf")
237
-
235
+ expect(crossref_xml.dig("doi_data", "collection", "item").length).to eq(5)
236
+ expect(crossref_xml.dig("doi_data", "collection", "item", 2, "resource")).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.54900/n6dnt-xpq48.pdf", "mime_type" => "application/pdf")
238
237
  end
239
238
 
240
239
  it "json_feed_item with references" do
@@ -267,8 +266,8 @@ describe Commonmeta::Metadata, vcr: true do
267
266
  expect(crossref_xml.dig("citation_list", "citation").last).to eq("article_title" => "The Research Software Alliance (ReSA) and the community landscape", "cYear" => "2020", "doi" => "10.5281/zenodo.3699950", "key" => "ref11")
268
267
  expect(crossref_xml.dig("item_number")).to eq("__content__" => "954f81380ecd409087c5cef1297f1470", "item_number_type" => "uuid")
269
268
  expect(crossref_xml.dig("group_title")).to eq("Humanities")
270
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource").length).to eq(4)
271
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource", 2)).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.54900/zwm7q-vet94.pdf", "mime_type" => "application/pdf")
269
+ expect(crossref_xml.dig("doi_data", "collection", "item").length).to eq(5)
270
+ expect(crossref_xml.dig("doi_data", "collection", "item", 2, "resource")).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.54900/zwm7q-vet94.pdf", "mime_type" => "application/pdf")
272
271
  end
273
272
 
274
273
  it "json_feed_item from rogue scholar with doi" do
@@ -298,8 +297,8 @@ describe Commonmeta::Metadata, vcr: true do
298
297
  "title")).to eq("EU-Mitgliedstaaten betonen die Rolle von wissenschaftsgeleiteten Open-Access-Modellen jenseits von APCs")
299
298
  expect(crossref_xml.dig("item_number")).to eq("__content__" => "1c57855813244493b8af84c49eabc52f", "item_number_type" => "uuid")
300
299
  expect(crossref_xml.dig("group_title")).to eq("Social sciences")
301
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource").length).to eq(4)
302
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource", 2)).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.59350/9ry27-7cz42.pdf", "mime_type" => "application/pdf")
300
+ expect(crossref_xml.dig("doi_data", "collection", "item").length).to eq(5)
301
+ expect(crossref_xml.dig("doi_data", "collection", "item", 2, "resource")).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.59350/9ry27-7cz42.pdf", "mime_type" => "application/pdf")
303
302
  end
304
303
 
305
304
  it "json_feed_item from rogue scholar with organizational author" do
@@ -328,8 +327,8 @@ describe Commonmeta::Metadata, vcr: true do
328
327
  "title")).to eq("KU Leuven supports ResearchEquals")
329
328
  expect(crossref_xml.dig("item_number")).to eq("__content__" => "5561f8e42ff14186a8d58dacb3afe414", "item_number_type" => "uuid")
330
329
  expect(crossref_xml.dig("group_title")).to eq("Social sciences")
331
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource").length).to eq(4)
332
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource", 2)).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.59350/9ry27-7cz42.pdf", "mime_type" => "application/pdf")
330
+ expect(crossref_xml.dig("doi_data", "collection", "item").length).to eq(5)
331
+ expect(crossref_xml.dig("doi_data", "collection", "item", 2, "resource")).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.59350/9ry27-7cz42.pdf", "mime_type" => "application/pdf")
333
332
  end
334
333
 
335
334
  it "json_feed_item from rogue scholar with archived content" do
@@ -369,8 +368,8 @@ describe Commonmeta::Metadata, vcr: true do
369
368
  "title")).to eq("ORCID Integration Series: PANGAEA")
370
369
  expect(crossref_xml.dig("item_number")).to eq("__content__" => "570c8129e86749e68517bd783627e76e", "item_number_type" => "uuid")
371
370
  expect(crossref_xml.dig("group_title")).to eq("Computer and information sciences")
372
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource").length).to eq(4)
373
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource", 2)).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.59350/faeph-x4x84.pdf", "mime_type" => "application/pdf")
371
+ expect(crossref_xml.dig("doi_data", "collection", "item").length).to eq(5)
372
+ expect(crossref_xml.dig("doi_data", "collection", "item", 2, "resource")).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.59350/faeph-x4x84.pdf", "mime_type" => "application/pdf")
374
373
  end
375
374
 
376
375
  it "json_feed_item from rogue scholar with relations" do
@@ -408,8 +407,8 @@ describe Commonmeta::Metadata, vcr: true do
408
407
  "title")).to eq("Differences between ORCID and DataCite Metadata")
409
408
  expect(crossref_xml.dig("item_number")).to eq("__content__" => "8a4de44333474b82b57de3c82b6485fc", "item_number_type" => "uuid")
410
409
  expect(crossref_xml.dig("group_title")).to eq("Computer and information sciences")
411
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource").length).to eq(4)
412
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource", 2)).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.53731/r79v4e1-97aq74v-ag578.pdf", "mime_type" => "application/pdf")
410
+ expect(crossref_xml.dig("doi_data", "collection", "item").length).to eq(5)
411
+ expect(crossref_xml.dig("doi_data", "collection", "item", 2, "resource")).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.53731/r79v4e1-97aq74v-ag578.pdf", "mime_type" => "application/pdf")
413
412
  end
414
413
 
415
414
  it "json_feed_item from rogue scholar with relations and funding" do
@@ -446,8 +445,8 @@ describe Commonmeta::Metadata, vcr: true do
446
445
  "title")).to eq("Tracking the Growth of the PID Graph")
447
446
  expect(crossref_xml.dig("item_number")).to eq("__content__" => "e58dc9c8b8704db28896238b3246c551", "item_number_type" => "uuid")
448
447
  expect(crossref_xml.dig("group_title")).to eq("Computer and information sciences")
449
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource").length).to eq(4)
450
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource", 2)).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.53731/r79s4nh-97aq74v-ag4t1.pdf", "mime_type" => "application/pdf")
448
+ expect(crossref_xml.dig("doi_data", "collection", "item").length).to eq(5)
449
+ expect(crossref_xml.dig("doi_data", "collection", "item", 2, "resource")).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.53731/r79s4nh-97aq74v-ag4t1.pdf", "mime_type" => "application/pdf")
451
450
  end
452
451
 
453
452
  it "json_feed_item from rogue scholar with anonymous author" do
@@ -481,8 +480,8 @@ describe Commonmeta::Metadata, vcr: true do
481
480
  "title")).to eq("Welcome to the Lab")
482
481
  expect(crossref_xml.dig("item_number")).to eq("__content__" => "a163e3405b3c47369ab08c54fdff6a3c", "item_number_type" => "uuid")
483
482
  expect(crossref_xml.dig("group_title")).to eq("Computer and information sciences")
484
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource").length).to eq(4)
485
- expect(crossref_xml.dig("doi_data", "collection", "item", "resource", 2)).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.59350/9ry27-7cz42.pdf", "mime_type" => "application/pdf")
483
+ expect(crossref_xml.dig("doi_data", "collection", "item").length).to eq(5)
484
+ expect(crossref_xml.dig("doi_data", "collection", "item", 2, "resource")).to eq("__content__" => "https://api.rogue-scholar.org/posts/10.59350/9ry27-7cz42.pdf", "mime_type" => "application/pdf")
486
485
  end
487
486
  end
488
487
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: commonmeta-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.8.1
4
+ version: 3.8.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Martin Fenner
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-01-09 00:00:00.000000000 Z
11
+ date: 2024-01-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport