bolognese 1.3.7 → 1.3.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 62d6900ccac1a79387dfaeb139e1bbde1290e208713528c143281740f060aac3
4
- data.tar.gz: 3e9ca8c795218bc24c1ddfc987729104a9f07cab8dc2d2eb4ceeff532c9aac59
3
+ metadata.gz: 4127494e63c31b7f8b996ab61cf0de1b701c9fe9c8a3425cfce35d36b26616fa
4
+ data.tar.gz: 1507ca847155914e3b34cfca03f2daaf0f2c5f3daa800fb6cef0d0fafe232423
5
5
  SHA512:
6
- metadata.gz: 0a2c2a6702e3f2eab29ee4f1f403f2696ed791e35603094dd0fa9b5c99e52029dfa4c103b196ae0d37e5fe90562c32f2f5b13324caa894298d713e208b6dfc25
7
- data.tar.gz: e24f6e14a045f64e6f7a3a957a957b4a1279ebeeea9296add2d9622e1bae4f9af8047c69c224671bd8491eaae8ac2c1769aa256065613701dfb96325b8186a5a
6
+ metadata.gz: bac7c3ba3f91fafc8e5c0dde8efb16000fef37ec8c1897e78c3dfe4cac5469f6698f9868c3e0935877620f8ff16cf8b1d0c09c17ef7ed92eea1448d482058a9a
7
+ data.tar.gz: 5d385c893e45d4138fdf43539e0555d444102dcad5a54230dc6ca5192697426eb221de87010f4da4db5c1d38b480345aa9668e6be6ba3034665b35abd23e7d16
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- bolognese (1.3.7)
4
+ bolognese (1.3.8)
5
5
  activesupport (>= 4.2.5, < 6)
6
6
  benchmark_methods (~> 0.7)
7
7
  bibtex-ruby (~> 4.1)
@@ -202,7 +202,7 @@ module Bolognese
202
202
  { "rightsUri" => normalize_url(parse_attributes(license)) }
203
203
  end.uniq
204
204
  else
205
- nil
205
+ []
206
206
  end
207
207
  end
208
208
 
@@ -209,7 +209,7 @@ module Bolognese
209
209
  "dates" => dates,
210
210
  "publication_year" => parse_attributes(meta.fetch("publicationYear", nil), first: true).to_s.strip.presence,
211
211
  "descriptions" => descriptions,
212
- "rights_list" => rights_list,
212
+ "rights_list" => Array.wrap(rights_list),
213
213
  "version_info" => meta.fetch("version", nil).to_s.presence,
214
214
  "subjects" => subjects,
215
215
  "language" => parse_attributes(meta.fetch("language", nil), first: true).to_s.strip.presence,
@@ -107,10 +107,10 @@ module Bolognese
107
107
  Array.wrap(schema_org_is_supplement_to(meta)) +
108
108
  Array.wrap(schema_org_is_supplemented_by(meta))
109
109
 
110
- rights_list = {
110
+ rights_list = [{
111
111
  "rightsUri" => parse_attributes(meta.fetch("license", nil), content: "id", first: true),
112
112
  "rights" => parse_attributes(meta.fetch("license", nil), content: "name", first: true)
113
- }
113
+ }]
114
114
 
115
115
  funding_references = Array.wrap(meta.fetch("funder", nil)).compact.map do |fr|
116
116
  if fr["@id"].present?
@@ -1,3 +1,3 @@
1
1
  module Bolognese
2
- VERSION = "1.3.7"
2
+ VERSION = "1.3.8"
3
3
  end
@@ -282,7 +282,7 @@ describe Bolognese::Metadata, vcr: true do
282
282
  expect(subject.publication_year).to eq("2019")
283
283
  expect(subject.id).to eq("https://doi.org/10.23698/aida/drov")
284
284
  expect(subject.publisher).to eq("AIDA")
285
- expect(subject.rights_list).to eq({"rights"=>"Restricted access", "rightsUri"=>"https://datasets.aida.medtech4health.se/10.23698/aida/drov#license"})
285
+ expect(subject.rights_list).to eq([{"rights"=>"Restricted access", "rightsUri"=>"https://datasets.aida.medtech4health.se/10.23698/aida/drov#license"}])
286
286
  expect(subject.id).to eq("https://doi.org/10.23698/aida/drov")
287
287
  end
288
288
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bolognese
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.7
4
+ version: 1.3.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Martin Fenner