relaton 0.5.13 → 0.5.14

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: 13f47436f2c7d74bd5161f1403a09aa648010048d54a43058171f8d51b642140
4
- data.tar.gz: 9adac27b508782690be25e6e3810d94f51f2fb4f8611bb3a448139288357227e
3
+ metadata.gz: 580a0949d35e36cab488ef5312598097a57ac2468d53733362ceb41e23c490b9
4
+ data.tar.gz: '069581b4725b0ce3035e57650f387db6a32948d75fbdcd2564bcc7a457d2bd58'
5
5
  SHA512:
6
- metadata.gz: 665bb1c4cd8adf9af1c59d5956bbd4fab63becbce3d0d077548f3619ae2e83b678135619408d6fcfe3db9b2b6a0a2a4210a2db8f9f9b4aad6d94d1f0facda0e1
7
- data.tar.gz: 14ff479e9700114c77ab79d7adfd0c4b4861ede726a7ffa7b56d86d80acb9f1bc292e32788046cfab64dd61d5a433c839ebedcfbabc3b9056b44ef4f4816e564
6
+ metadata.gz: 75cb8981099261b2693553f74830221d461b5e84342304e599a5ce49e0f9a3d9b2bc42082f608964d241643b1b9a7b36cd6c50209ed5358733bca0f60174e2de
7
+ data.tar.gz: 1ca57cf36135a79fb006c9beae32eaf109567548b6ce6a99b113144609fe5795d3ee5fab546a6c840321f515761bad846106a2abac74e366dca5d589c516b27b
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- relaton (0.5.13)
4
+ relaton (0.5.14)
5
5
  relaton-calconnect (~> 0.1.0)
6
6
  relaton-gb (~> 0.6.0)
7
7
  relaton-iec (~> 0.4.0)
data/lib/relaton/db.rb CHANGED
@@ -181,7 +181,7 @@ module Relaton
181
181
  bib_id = bib&.docidentifier&.first&.id
182
182
 
183
183
  # when docid doesn't match bib's id then return a reference to bib's id
184
- if args[:db] && args[:id] && bib_id && args[:id] !~ %r{\(#{bib_id}\)}
184
+ if args[:db] && args[:id] && bib_id && args[:id] !~ %r{#{Regexp.quote("(#{bib_id})")}}
185
185
  bid = std_id(bib.docidentifier.first.id, nil, {}, stdclass).first
186
186
  args[:db][bid] ||= bib_entry bib
187
187
  "redirection #{bid}"
@@ -1 +1 @@
1
- 0.5.13
1
+ 0.5.14
@@ -1,3 +1,3 @@
1
1
  module Relaton
2
- VERSION = "0.5.13".freeze
2
+ VERSION = "0.5.14".freeze
3
3
  end
@@ -1 +1 @@
1
- 0.5.13
1
+ 0.5.14
data/spec/relaton_spec.rb CHANGED
@@ -35,10 +35,19 @@ RSpec.describe Relaton::Db do
35
35
  end
36
36
  end
37
37
 
38
- it "all parts" do
39
- VCR.use_cassette "iso_19115" do
40
- bib = @db.fetch("ISO 19115", nil, {})
41
- expect(bib).to be_instance_of RelatonIsoBib::IsoBibliographicItem
38
+ context "all parts" do
39
+ it "implicity" do
40
+ VCR.use_cassette "iso_19115" do
41
+ bib = @db.fetch("ISO 19115", nil, {})
42
+ expect(bib).to be_instance_of RelatonIsoBib::IsoBibliographicItem
43
+ end
44
+ end
45
+
46
+ it "explicity" do
47
+ VCR.use_cassette "iso_19115" do
48
+ bib = @db.fetch("ISO 19115 (all parts)", nil, {})
49
+ expect(bib).to be_instance_of RelatonIsoBib::IsoBibliographicItem
50
+ end
42
51
  end
43
52
  end
44
53
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: relaton
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.13
4
+ version: 0.5.14
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-11-11 00:00:00.000000000 Z
11
+ date: 2019-11-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: relaton-calconnect