enju_ndl 0.1.0.pre18 → 0.1.0.pre19

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.
Files changed (27) hide show
  1. checksums.yaml +4 -4
  2. data/lib/enju_ndl/ndl_search.rb +2 -2
  3. data/lib/enju_ndl/version.rb +1 -1
  4. data/spec/cassette_library/NdlBook/import/should_get_series_title.yml +5 -7
  5. data/spec/cassette_library/NdlBook/import/should_get_volume_number.yml +6 -8
  6. data/spec/cassette_library/NdlBook/import/should_import_audio_cd.yml +5 -7
  7. data/spec/cassette_library/NdlBook/import/should_import_bibliographic_record.yml +6 -8
  8. data/spec/cassette_library/NdlBook/import/should_import_bibliographic_record_that_does_not_have_any_classifications.yml +5 -7
  9. data/spec/cassette_library/NdlBook/import/should_import_pud_date_is_nil.yml +6 -8
  10. data/spec/cassette_library/NdlBook/import/should_import_series_statement.yml +5 -7
  11. data/spec/cassette_library/NdlBook/import/should_import_series_statement_if_the_resource_is_periodical.yml +181 -165
  12. data/spec/cassette_library/NdlBook/import/should_import_title_alternative.yml +8 -10
  13. data/spec/cassette_library/NdlBook/import/should_import_url_contain_whitespace.yml +6 -8
  14. data/spec/cassette_library/NdlBook/import/should_import_video_dvd.yml +6 -8
  15. data/spec/cassette_library/NdlBook/import/should_import_volume_number_string.yml +146 -147
  16. data/spec/cassette_library/NdlBook/import/should_not_get_series_title_if_book_has_not_series_title.yml +6 -8
  17. data/spec/cassette_library/NdlBook/import/should_not_get_volume_number_if_book_has_not_volume.yml +5 -7
  18. data/spec/cassette_library/NdlBook/search/should_not_distinguish_double_byte_space_from_one-byte_space_in_a_query.yml +12 -16
  19. data/spec/cassette_library/NdlBook/search/should_search_bibliographic_record.yml +8 -10
  20. data/spec/cassette_library/NdlBooksController/GET_index/should_get_index.yml +95 -97
  21. data/spec/cassette_library/NdlBooksController/POST_create/should_create_a_bibliographic_record_if_nbn_is_set.yml +6 -8
  22. data/spec/cassette_library/NdlBooksController/POST_create/should_not_create_a_bibliographic_record_if_nbn_is_not_set.yml +6 -8
  23. data/spec/cassette_library/Question/should_respond_to_search_crd.yml +3 -3
  24. data/spec/dummy/db/development.sqlite3 +0 -0
  25. data/spec/dummy/db/test.sqlite3 +0 -0
  26. data/spec/models/ndl_book_spec.rb +1 -1
  27. metadata +6 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 67119193c2eaec7c7eff5c0d497049fe06f8c211
4
- data.tar.gz: 5ca2e9a711979c33f3f57fa72c6ce5c86308519e
3
+ metadata.gz: 505852854109922926380ed50132dd72b5484ca9
4
+ data.tar.gz: 34e5040dbaf5f59fa8608185e3dce3b32afe73be
5
5
  SHA512:
6
- metadata.gz: a989ab41f543b66d9b2ae6c2b71df1d6e4ce16ad75479c5696005d24d8521b943a6ff05d61ef08a743182bfcfa22343af402ca1f625c7a0bd12e64566df93aeb
7
- data.tar.gz: e1ac2597944e71b47e5fc818470309753f79d630760a5579aaedbb3038d87df2b54b6783473949a9aac6865ebdee386633de0d8c59ca87bb3cd195ccae052cf8
6
+ metadata.gz: 658f7b37989e190098bae889a312ec2c54947fef4814767b61b67a449d57dee8323435e780258dae5ed8b12be7f45254c016e6bf01248955292266b2488eb556
7
+ data.tar.gz: 20dc0bd5fff548c7d7a7fb5fc17b52dcf5f387534575363be4230bed4253a0446a71c46c9ff26a82c5e7e5fbe26f096a9924a02a4c20575c089172adfdb18383
@@ -135,13 +135,13 @@ module EnjuNdl
135
135
  subject = Subject.where(:term => term[:term]).first
136
136
  unless subject
137
137
  subject = Subject.new(term)
138
+ subject.subject_heading_type = subject_heading_type
138
139
  subject.subject_type = SubjectType.find(1)
139
- subject.save!
140
140
  end
141
141
  if subject.valid?
142
- subject.subject_heading_type = subject_heading_type
143
142
  manifestation.subjects << subject
144
143
  end
144
+ subject.save!
145
145
  end
146
146
  if classification_urls
147
147
  ndc9_url = classification_urls.map{|url| URI.parse(URI.escape(url))}.select{|u| u.path.split('/').reverse[1] == 'ndc9'}.first
@@ -1,3 +1,3 @@
1
1
  module EnjuNdl
2
- VERSION = "0.1.0.pre18"
2
+ VERSION = "0.1.0.pre19"
3
3
  end
@@ -19,17 +19,15 @@ http_interactions:
19
19
  message: OK
20
20
  headers:
21
21
  date:
22
- - Wed, 10 Apr 2013 02:43:51 GMT
22
+ - Mon, 06 May 2013 19:53:04 GMT
23
23
  server:
24
24
  - Apache
25
- x-powered-by:
26
- - Phusion Passenger (mod_rails/mod_rack) 2.2.15
27
25
  etag:
28
26
  - '"ee2d4806ca5e9cc7403233ccc34436af"'
29
27
  x-ua-compatible:
30
28
  - IE=Edge,chrome=1
31
29
  x-runtime:
32
- - '0.222430'
30
+ - '0.256298'
33
31
  cache-control:
34
32
  - max-age=0, private, must-revalidate
35
33
  status:
@@ -37,8 +35,8 @@ http_interactions:
37
35
  content-type:
38
36
  - application/xml; charset=utf-8
39
37
  set-cookie:
40
- - _front_session_id=c074feccdbb7d54773865f76e7ac53ca; domain=.iss.ndl.go.jp;
41
- path=/; expires=Wed, 10-Apr-2013 03:43:51 GMT; HttpOnly
38
+ - _front_session_id=657a8696f2d7c6c9ecb803b98162718e; domain=.iss.ndl.go.jp;
39
+ path=/; expires=Mon, 06-May-2013 20:53:04 GMT; HttpOnly
42
40
  - serverid=1102; path=/
43
41
  vary:
44
42
  - Accept-Encoding,User-Agent
@@ -111,5 +109,5 @@ http_interactions:
111
109
  dHA6Ly9pZC5uZGwuZ28uanAvYmliLzAwMDAwODE4MDAwMyIvPgogICAgPC9p
112
110
  dGVtPgogIDwvY2hhbm5lbD4KPC9yc3M+Cg==
113
111
  http_version: '1.0'
114
- recorded_at: Wed, 10 Apr 2013 02:43:52 GMT
112
+ recorded_at: Mon, 06 May 2013 19:53:04 GMT
115
113
  recorded_with: VCR 2.4.0
@@ -19,17 +19,15 @@ http_interactions:
19
19
  message: OK
20
20
  headers:
21
21
  date:
22
- - Wed, 10 Apr 2013 02:43:51 GMT
22
+ - Mon, 06 May 2013 19:53:04 GMT
23
23
  server:
24
24
  - Apache
25
- x-powered-by:
26
- - Phusion Passenger (mod_rails/mod_rack) 2.2.15
27
25
  etag:
28
26
  - '"867921384dfb763ce72815f16b2b5dc1"'
29
27
  x-ua-compatible:
30
28
  - IE=Edge,chrome=1
31
29
  x-runtime:
32
- - '0.259952'
30
+ - '0.212838'
33
31
  cache-control:
34
32
  - max-age=0, private, must-revalidate
35
33
  status:
@@ -37,9 +35,9 @@ http_interactions:
37
35
  content-type:
38
36
  - application/xml; charset=utf-8
39
37
  set-cookie:
40
- - _front_session_id=c0a313bb37c8a017568b09ab18c626cd; domain=.iss.ndl.go.jp;
41
- path=/; expires=Wed, 10-Apr-2013 03:43:51 GMT; HttpOnly
42
- - serverid=1101; path=/
38
+ - _front_session_id=75b6f5fd54fb92c4fa38287572b2e960; domain=.iss.ndl.go.jp;
39
+ path=/; expires=Mon, 06-May-2013 20:53:04 GMT; HttpOnly
40
+ - serverid=1105; path=/
43
41
  vary:
44
42
  - Accept-Encoding,User-Agent
45
43
  content-encoding:
@@ -112,5 +110,5 @@ http_interactions:
112
110
  OnJlc291cmNlPSJodHRwOi8vaWQubmRsLmdvLmpwL2JpYi8wMjM1OTE1MjMi
113
111
  Lz4KICAgIDwvaXRlbT4KICA8L2NoYW5uZWw+CjwvcnNzPgo=
114
112
  http_version: '1.0'
115
- recorded_at: Wed, 10 Apr 2013 02:43:51 GMT
113
+ recorded_at: Mon, 06 May 2013 19:53:04 GMT
116
114
  recorded_with: VCR 2.4.0
@@ -19,17 +19,15 @@ http_interactions:
19
19
  message: OK
20
20
  headers:
21
21
  date:
22
- - Wed, 10 Apr 2013 02:43:50 GMT
22
+ - Mon, 06 May 2013 19:53:02 GMT
23
23
  server:
24
24
  - Apache
25
- x-powered-by:
26
- - Phusion Passenger (mod_rails/mod_rack) 2.2.15
27
25
  etag:
28
26
  - '"e7a15123a0111d146ca1e13b19293c5e"'
29
27
  x-ua-compatible:
30
28
  - IE=Edge,chrome=1
31
29
  x-runtime:
32
- - '0.078273'
30
+ - '0.170931'
33
31
  cache-control:
34
32
  - max-age=0, private, must-revalidate
35
33
  status:
@@ -37,8 +35,8 @@ http_interactions:
37
35
  content-type:
38
36
  - application/xml; charset=utf-8
39
37
  set-cookie:
40
- - _front_session_id=1ed4069b623d21e99ff9b76ebd9b2cac; domain=.iss.ndl.go.jp;
41
- path=/; expires=Wed, 10-Apr-2013 03:43:50 GMT; HttpOnly
38
+ - _front_session_id=d5bbfeff0649b267559c41614df68f40; domain=.iss.ndl.go.jp;
39
+ path=/; expires=Mon, 06-May-2013 20:53:03 GMT; HttpOnly
42
40
  - serverid=1101; path=/
43
41
  vary:
44
42
  - Accept-Encoding,User-Agent
@@ -158,5 +156,5 @@ http_interactions:
158
156
  PjE8L3JlY29yZFBvc2l0aW9uPgogICAgPC9yZWNvcmQ+CiAgPC9yZWNvcmRz
159
157
  Pgo8L3NlYXJjaFJldHJpZXZlUmVzcG9uc2U+Cg==
160
158
  http_version: '1.0'
161
- recorded_at: Wed, 10 Apr 2013 02:43:50 GMT
159
+ recorded_at: Mon, 06 May 2013 19:53:03 GMT
162
160
  recorded_with: VCR 2.4.0
@@ -19,17 +19,15 @@ http_interactions:
19
19
  message: OK
20
20
  headers:
21
21
  date:
22
- - Wed, 10 Apr 2013 02:43:46 GMT
22
+ - Mon, 06 May 2013 19:52:54 GMT
23
23
  server:
24
24
  - Apache
25
- x-powered-by:
26
- - Phusion Passenger (mod_rails/mod_rack) 2.2.15
27
25
  etag:
28
26
  - '"74b53615ca1d8ecc7b2e0691b9c87ba2"'
29
27
  x-ua-compatible:
30
28
  - IE=Edge,chrome=1
31
29
  x-runtime:
32
- - '0.370741'
30
+ - '0.247530'
33
31
  cache-control:
34
32
  - max-age=0, private, must-revalidate
35
33
  status:
@@ -37,9 +35,9 @@ http_interactions:
37
35
  content-type:
38
36
  - application/xml; charset=utf-8
39
37
  set-cookie:
40
- - _front_session_id=63bb6ebec9ef5c129f360f58269523e9; domain=.iss.ndl.go.jp;
41
- path=/; expires=Wed, 10-Apr-2013 03:43:46 GMT; HttpOnly
42
- - serverid=1105; path=/
38
+ - _front_session_id=f62dd4f1911cfdba14099561a88fb8dd; domain=.iss.ndl.go.jp;
39
+ path=/; expires=Mon, 06-May-2013 20:52:55 GMT; HttpOnly
40
+ - serverid=1102; path=/
43
41
  vary:
44
42
  - Accept-Encoding,User-Agent
45
43
  content-encoding:
@@ -192,5 +190,5 @@ http_interactions:
192
190
  b24+MTwvcmVjb3JkUG9zaXRpb24+CiAgICA8L3JlY29yZD4KICA8L3JlY29y
193
191
  ZHM+Cjwvc2VhcmNoUmV0cmlldmVSZXNwb25zZT4K
194
192
  http_version: '1.0'
195
- recorded_at: Wed, 10 Apr 2013 02:43:47 GMT
193
+ recorded_at: Mon, 06 May 2013 19:52:55 GMT
196
194
  recorded_with: VCR 2.4.0
@@ -19,17 +19,15 @@ http_interactions:
19
19
  message: OK
20
20
  headers:
21
21
  date:
22
- - Wed, 10 Apr 2013 02:43:47 GMT
22
+ - Mon, 06 May 2013 19:52:55 GMT
23
23
  server:
24
24
  - Apache
25
- x-powered-by:
26
- - Phusion Passenger (mod_rails/mod_rack) 2.2.15
27
25
  etag:
28
26
  - '"73722c8c17a20851f281ebf39c595010"'
29
27
  x-ua-compatible:
30
28
  - IE=Edge,chrome=1
31
29
  x-runtime:
32
- - '0.226711'
30
+ - '0.234703'
33
31
  cache-control:
34
32
  - max-age=0, private, must-revalidate
35
33
  status:
@@ -37,8 +35,8 @@ http_interactions:
37
35
  content-type:
38
36
  - application/xml; charset=utf-8
39
37
  set-cookie:
40
- - _front_session_id=2104556fe84eebb96957ebecc3d28056; domain=.iss.ndl.go.jp;
41
- path=/; expires=Wed, 10-Apr-2013 03:43:47 GMT; HttpOnly
38
+ - _front_session_id=9bb0c16633aaeae80f127930a050c849; domain=.iss.ndl.go.jp;
39
+ path=/; expires=Mon, 06-May-2013 20:52:56 GMT; HttpOnly
42
40
  - serverid=1102; path=/
43
41
  vary:
44
42
  - Accept-Encoding,User-Agent
@@ -184,5 +182,5 @@ http_interactions:
184
182
  PjE8L3JlY29yZFBvc2l0aW9uPgogICAgPC9yZWNvcmQ+CiAgPC9yZWNvcmRz
185
183
  Pgo8L3NlYXJjaFJldHJpZXZlUmVzcG9uc2U+Cg==
186
184
  http_version: '1.0'
187
- recorded_at: Wed, 10 Apr 2013 02:43:47 GMT
185
+ recorded_at: Mon, 06 May 2013 19:52:56 GMT
188
186
  recorded_with: VCR 2.4.0
@@ -19,17 +19,15 @@ http_interactions:
19
19
  message: OK
20
20
  headers:
21
21
  date:
22
- - Wed, 10 Apr 2013 02:43:49 GMT
22
+ - Mon, 06 May 2013 19:53:01 GMT
23
23
  server:
24
24
  - Apache
25
- x-powered-by:
26
- - Phusion Passenger (mod_rails/mod_rack) 2.2.15
27
25
  etag:
28
26
  - '"fb711444cf034b78f89c1e825b0a5c1e"'
29
27
  x-ua-compatible:
30
28
  - IE=Edge,chrome=1
31
29
  x-runtime:
32
- - '0.157770'
30
+ - '0.172234'
33
31
  cache-control:
34
32
  - max-age=0, private, must-revalidate
35
33
  status:
@@ -37,9 +35,9 @@ http_interactions:
37
35
  content-type:
38
36
  - application/xml; charset=utf-8
39
37
  set-cookie:
40
- - _front_session_id=b9eb82b4ffc889411744b7b889e40ab2; domain=.iss.ndl.go.jp;
41
- path=/; expires=Wed, 10-Apr-2013 03:43:50 GMT; HttpOnly
42
- - serverid=1101; path=/
38
+ - _front_session_id=845c4031f7010e3050e8bb2998fc8963; domain=.iss.ndl.go.jp;
39
+ path=/; expires=Mon, 06-May-2013 20:53:01 GMT; HttpOnly
40
+ - serverid=1105; path=/
43
41
  vary:
44
42
  - Accept-Encoding,User-Agent
45
43
  content-encoding:
@@ -140,5 +138,5 @@ http_interactions:
140
138
  dGlvbj4KICAgIDwvcmVjb3JkPgogIDwvcmVjb3Jkcz4KPC9zZWFyY2hSZXRy
141
139
  aWV2ZVJlc3BvbnNlPgo=
142
140
  http_version: '1.0'
143
- recorded_at: Wed, 10 Apr 2013 02:43:50 GMT
141
+ recorded_at: Mon, 06 May 2013 19:53:01 GMT
144
142
  recorded_with: VCR 2.4.0
@@ -19,17 +19,15 @@ http_interactions:
19
19
  message: OK
20
20
  headers:
21
21
  date:
22
- - Wed, 10 Apr 2013 02:43:48 GMT
22
+ - Mon, 06 May 2013 19:52:59 GMT
23
23
  server:
24
24
  - Apache
25
- x-powered-by:
26
- - Phusion Passenger (mod_rails/mod_rack) 2.2.15
27
25
  etag:
28
26
  - '"319acca9ae72b9a71b36af9e455982be"'
29
27
  x-ua-compatible:
30
28
  - IE=Edge,chrome=1
31
29
  x-runtime:
32
- - '0.119390'
30
+ - '0.258405'
33
31
  cache-control:
34
32
  - max-age=0, private, must-revalidate
35
33
  status:
@@ -37,8 +35,8 @@ http_interactions:
37
35
  content-type:
38
36
  - application/xml; charset=utf-8
39
37
  set-cookie:
40
- - _front_session_id=94117645cbb848521a51ad089050f369; domain=.iss.ndl.go.jp;
41
- path=/; expires=Wed, 10-Apr-2013 03:43:49 GMT; HttpOnly
38
+ - _front_session_id=e488b2c7f1d49a1a9da942bba092779d; domain=.iss.ndl.go.jp;
39
+ path=/; expires=Mon, 06-May-2013 20:53:00 GMT; HttpOnly
42
40
  - serverid=1105; path=/
43
41
  vary:
44
42
  - Accept-Encoding,User-Agent
@@ -221,5 +219,5 @@ http_interactions:
221
219
  b3JkUG9zaXRpb24+MTwvcmVjb3JkUG9zaXRpb24+CiAgICA8L3JlY29yZD4K
222
220
  ICA8L3JlY29yZHM+Cjwvc2VhcmNoUmV0cmlldmVSZXNwb25zZT4K
223
221
  http_version: '1.0'
224
- recorded_at: Wed, 10 Apr 2013 02:43:49 GMT
222
+ recorded_at: Mon, 06 May 2013 19:53:00 GMT
225
223
  recorded_with: VCR 2.4.0