active-fedora 7.0.0.rc1 → 7.0.0.rc2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/active_fedora/attributes.rb +15 -20
- data/lib/active_fedora/datastream.rb +9 -4
- data/lib/active_fedora/datastream_attribute.rb +33 -38
- data/lib/active_fedora/datastream_hash.rb +2 -2
- data/lib/active_fedora/datastreams.rb +43 -31
- data/lib/active_fedora/datastreams/nokogiri_datastreams.rb +146 -0
- data/lib/active_fedora/digital_object.rb +2 -2
- data/lib/active_fedora/indexing.rb +1 -1
- data/lib/active_fedora/nom_datastream.rb +7 -23
- data/lib/active_fedora/om_datastream.rb +3 -130
- data/lib/active_fedora/rdf_datastream.rb +4 -0
- data/lib/active_fedora/rdf_node.rb +1 -0
- data/lib/active_fedora/rdf_object.rb +1 -7
- data/lib/active_fedora/relation.rb +0 -29
- data/lib/active_fedora/relation/query_methods.rb +36 -0
- data/lib/active_fedora/simple_datastream.rb +1 -0
- data/lib/active_fedora/version.rb +1 -1
- data/spec/integration/base_spec.rb +2 -1
- data/spec/integration/om_datastream_spec.rb +2 -2
- data/spec/integration/scoped_query_spec.rb +13 -0
- data/spec/samples/hydra-mods_article_datastream.rb +1 -1
- data/spec/unit/datastream_spec.rb +0 -41
- data/spec/unit/datastreams_spec.rb +3 -3
- data/spec/unit/om_datastream_spec.rb +4 -1
- metadata +44 -43
@@ -25,12 +25,12 @@ describe ActiveFedora::Datastreams do
|
|
25
25
|
|
26
26
|
it "should raise an error if you don't give a type" do
|
27
27
|
expect{ FooHistory.has_metadata "bob" }.to raise_error ArgumentError,
|
28
|
-
"You must provide a :type property for the
|
28
|
+
"You must provide a :type property for the datastream 'bob'"
|
29
29
|
end
|
30
30
|
|
31
31
|
it "should raise an error if you don't give a dsid" do
|
32
32
|
expect{ FooHistory.has_metadata type: ActiveFedora::SimpleDatastream }.to raise_error ArgumentError,
|
33
|
-
"You must provide a name (dsid) for the
|
33
|
+
"You must provide a name (dsid) for the datastream"
|
34
34
|
end
|
35
35
|
end
|
36
36
|
|
@@ -136,7 +136,7 @@ describe ActiveFedora::Datastreams do
|
|
136
136
|
|
137
137
|
describe "#datastream_from_spec" do
|
138
138
|
it "should fetch the rubydora datastream" do
|
139
|
-
subject.inner_object.should_receive(:datastream_object_for).with('dsid', {})
|
139
|
+
subject.inner_object.should_receive(:datastream_object_for).with('dsid', {}, {})
|
140
140
|
subject.datastream_from_spec({}, 'dsid')
|
141
141
|
end
|
142
142
|
end
|
@@ -92,15 +92,18 @@ describe ActiveFedora::OmDatastream do
|
|
92
92
|
"foo__"
|
93
93
|
end
|
94
94
|
end
|
95
|
+
subject.title = 'Science'
|
95
96
|
end
|
96
97
|
after do
|
97
98
|
Object.send(:remove_const, :MyDatastream)
|
98
99
|
end
|
99
100
|
subject { MyDatastream.new }
|
100
101
|
it "should use the prefix" do
|
101
|
-
subject.title = 'Science'
|
102
102
|
expect(subject.to_solr).to have_key('foo__title_tesim')
|
103
103
|
end
|
104
|
+
it "should not prefix fields that aren't defined by this datastream" do
|
105
|
+
expect(subject.to_solr('id' => 'test:123')).to have_key('id')
|
106
|
+
end
|
104
107
|
end
|
105
108
|
end
|
106
109
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: active-fedora
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.0.0.
|
4
|
+
version: 7.0.0.rc2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matt Zumwalt
|
@@ -10,244 +10,244 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2014-
|
13
|
+
date: 2014-02-10 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rsolr
|
17
17
|
requirement: !ruby/object:Gem::Requirement
|
18
18
|
requirements:
|
19
|
-
- - ~>
|
19
|
+
- - "~>"
|
20
20
|
- !ruby/object:Gem::Version
|
21
21
|
version: 1.0.10.pre1
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
25
|
requirements:
|
26
|
-
- - ~>
|
26
|
+
- - "~>"
|
27
27
|
- !ruby/object:Gem::Version
|
28
28
|
version: 1.0.10.pre1
|
29
29
|
- !ruby/object:Gem::Dependency
|
30
30
|
name: om
|
31
31
|
requirement: !ruby/object:Gem::Requirement
|
32
32
|
requirements:
|
33
|
-
- - ~>
|
33
|
+
- - "~>"
|
34
34
|
- !ruby/object:Gem::Version
|
35
35
|
version: 3.0.0
|
36
36
|
type: :runtime
|
37
37
|
prerelease: false
|
38
38
|
version_requirements: !ruby/object:Gem::Requirement
|
39
39
|
requirements:
|
40
|
-
- - ~>
|
40
|
+
- - "~>"
|
41
41
|
- !ruby/object:Gem::Version
|
42
42
|
version: 3.0.0
|
43
43
|
- !ruby/object:Gem::Dependency
|
44
44
|
name: nom-xml
|
45
45
|
requirement: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
|
-
- -
|
47
|
+
- - ">="
|
48
48
|
- !ruby/object:Gem::Version
|
49
49
|
version: 0.5.1
|
50
50
|
type: :runtime
|
51
51
|
prerelease: false
|
52
52
|
version_requirements: !ruby/object:Gem::Requirement
|
53
53
|
requirements:
|
54
|
-
- -
|
54
|
+
- - ">="
|
55
55
|
- !ruby/object:Gem::Version
|
56
56
|
version: 0.5.1
|
57
57
|
- !ruby/object:Gem::Dependency
|
58
58
|
name: activesupport
|
59
59
|
requirement: !ruby/object:Gem::Requirement
|
60
60
|
requirements:
|
61
|
-
- -
|
61
|
+
- - ">="
|
62
62
|
- !ruby/object:Gem::Version
|
63
63
|
version: 3.0.0
|
64
64
|
type: :runtime
|
65
65
|
prerelease: false
|
66
66
|
version_requirements: !ruby/object:Gem::Requirement
|
67
67
|
requirements:
|
68
|
-
- -
|
68
|
+
- - ">="
|
69
69
|
- !ruby/object:Gem::Version
|
70
70
|
version: 3.0.0
|
71
71
|
- !ruby/object:Gem::Dependency
|
72
72
|
name: mediashelf-loggable
|
73
73
|
requirement: !ruby/object:Gem::Requirement
|
74
74
|
requirements:
|
75
|
-
- -
|
75
|
+
- - ">="
|
76
76
|
- !ruby/object:Gem::Version
|
77
77
|
version: '0'
|
78
78
|
type: :runtime
|
79
79
|
prerelease: false
|
80
80
|
version_requirements: !ruby/object:Gem::Requirement
|
81
81
|
requirements:
|
82
|
-
- -
|
82
|
+
- - ">="
|
83
83
|
- !ruby/object:Gem::Version
|
84
84
|
version: '0'
|
85
85
|
- !ruby/object:Gem::Dependency
|
86
86
|
name: rubydora
|
87
87
|
requirement: !ruby/object:Gem::Requirement
|
88
88
|
requirements:
|
89
|
-
- - ~>
|
89
|
+
- - "~>"
|
90
90
|
- !ruby/object:Gem::Version
|
91
91
|
version: 1.7.0
|
92
92
|
type: :runtime
|
93
93
|
prerelease: false
|
94
94
|
version_requirements: !ruby/object:Gem::Requirement
|
95
95
|
requirements:
|
96
|
-
- - ~>
|
96
|
+
- - "~>"
|
97
97
|
- !ruby/object:Gem::Version
|
98
98
|
version: 1.7.0
|
99
99
|
- !ruby/object:Gem::Dependency
|
100
100
|
name: rdf
|
101
101
|
requirement: !ruby/object:Gem::Requirement
|
102
102
|
requirements:
|
103
|
-
- -
|
103
|
+
- - ">="
|
104
104
|
- !ruby/object:Gem::Version
|
105
105
|
version: '0'
|
106
106
|
type: :runtime
|
107
107
|
prerelease: false
|
108
108
|
version_requirements: !ruby/object:Gem::Requirement
|
109
109
|
requirements:
|
110
|
-
- -
|
110
|
+
- - ">="
|
111
111
|
- !ruby/object:Gem::Version
|
112
112
|
version: '0'
|
113
113
|
- !ruby/object:Gem::Dependency
|
114
114
|
name: rdf-rdfxml
|
115
115
|
requirement: !ruby/object:Gem::Requirement
|
116
116
|
requirements:
|
117
|
-
- - ~>
|
117
|
+
- - "~>"
|
118
118
|
- !ruby/object:Gem::Version
|
119
119
|
version: 1.1.0
|
120
120
|
type: :runtime
|
121
121
|
prerelease: false
|
122
122
|
version_requirements: !ruby/object:Gem::Requirement
|
123
123
|
requirements:
|
124
|
-
- - ~>
|
124
|
+
- - "~>"
|
125
125
|
- !ruby/object:Gem::Version
|
126
126
|
version: 1.1.0
|
127
127
|
- !ruby/object:Gem::Dependency
|
128
128
|
name: deprecation
|
129
129
|
requirement: !ruby/object:Gem::Requirement
|
130
130
|
requirements:
|
131
|
-
- -
|
131
|
+
- - ">="
|
132
132
|
- !ruby/object:Gem::Version
|
133
133
|
version: '0'
|
134
134
|
type: :runtime
|
135
135
|
prerelease: false
|
136
136
|
version_requirements: !ruby/object:Gem::Requirement
|
137
137
|
requirements:
|
138
|
-
- -
|
138
|
+
- - ">="
|
139
139
|
- !ruby/object:Gem::Version
|
140
140
|
version: '0'
|
141
141
|
- !ruby/object:Gem::Dependency
|
142
142
|
name: rdoc
|
143
143
|
requirement: !ruby/object:Gem::Requirement
|
144
144
|
requirements:
|
145
|
-
- -
|
145
|
+
- - ">="
|
146
146
|
- !ruby/object:Gem::Version
|
147
147
|
version: '0'
|
148
148
|
type: :development
|
149
149
|
prerelease: false
|
150
150
|
version_requirements: !ruby/object:Gem::Requirement
|
151
151
|
requirements:
|
152
|
-
- -
|
152
|
+
- - ">="
|
153
153
|
- !ruby/object:Gem::Version
|
154
154
|
version: '0'
|
155
155
|
- !ruby/object:Gem::Dependency
|
156
156
|
name: yard
|
157
157
|
requirement: !ruby/object:Gem::Requirement
|
158
158
|
requirements:
|
159
|
-
- -
|
159
|
+
- - ">="
|
160
160
|
- !ruby/object:Gem::Version
|
161
161
|
version: '0'
|
162
162
|
type: :development
|
163
163
|
prerelease: false
|
164
164
|
version_requirements: !ruby/object:Gem::Requirement
|
165
165
|
requirements:
|
166
|
-
- -
|
166
|
+
- - ">="
|
167
167
|
- !ruby/object:Gem::Version
|
168
168
|
version: '0'
|
169
169
|
- !ruby/object:Gem::Dependency
|
170
170
|
name: rake
|
171
171
|
requirement: !ruby/object:Gem::Requirement
|
172
172
|
requirements:
|
173
|
-
- -
|
173
|
+
- - ">="
|
174
174
|
- !ruby/object:Gem::Version
|
175
175
|
version: '0'
|
176
176
|
type: :development
|
177
177
|
prerelease: false
|
178
178
|
version_requirements: !ruby/object:Gem::Requirement
|
179
179
|
requirements:
|
180
|
-
- -
|
180
|
+
- - ">="
|
181
181
|
- !ruby/object:Gem::Version
|
182
182
|
version: '0'
|
183
183
|
- !ruby/object:Gem::Dependency
|
184
184
|
name: jettywrapper
|
185
185
|
requirement: !ruby/object:Gem::Requirement
|
186
186
|
requirements:
|
187
|
-
- -
|
187
|
+
- - ">="
|
188
188
|
- !ruby/object:Gem::Version
|
189
189
|
version: 1.4.0
|
190
190
|
type: :development
|
191
191
|
prerelease: false
|
192
192
|
version_requirements: !ruby/object:Gem::Requirement
|
193
193
|
requirements:
|
194
|
-
- -
|
194
|
+
- - ">="
|
195
195
|
- !ruby/object:Gem::Version
|
196
196
|
version: 1.4.0
|
197
197
|
- !ruby/object:Gem::Dependency
|
198
198
|
name: rspec
|
199
199
|
requirement: !ruby/object:Gem::Requirement
|
200
200
|
requirements:
|
201
|
-
- -
|
201
|
+
- - ">="
|
202
202
|
- !ruby/object:Gem::Version
|
203
203
|
version: 2.9.0
|
204
204
|
type: :development
|
205
205
|
prerelease: false
|
206
206
|
version_requirements: !ruby/object:Gem::Requirement
|
207
207
|
requirements:
|
208
|
-
- -
|
208
|
+
- - ">="
|
209
209
|
- !ruby/object:Gem::Version
|
210
210
|
version: 2.9.0
|
211
211
|
- !ruby/object:Gem::Dependency
|
212
212
|
name: equivalent-xml
|
213
213
|
requirement: !ruby/object:Gem::Requirement
|
214
214
|
requirements:
|
215
|
-
- -
|
215
|
+
- - ">="
|
216
216
|
- !ruby/object:Gem::Version
|
217
217
|
version: '0'
|
218
218
|
type: :development
|
219
219
|
prerelease: false
|
220
220
|
version_requirements: !ruby/object:Gem::Requirement
|
221
221
|
requirements:
|
222
|
-
- -
|
222
|
+
- - ">="
|
223
223
|
- !ruby/object:Gem::Version
|
224
224
|
version: '0'
|
225
225
|
- !ruby/object:Gem::Dependency
|
226
226
|
name: rest-client
|
227
227
|
requirement: !ruby/object:Gem::Requirement
|
228
228
|
requirements:
|
229
|
-
- -
|
229
|
+
- - ">="
|
230
230
|
- !ruby/object:Gem::Version
|
231
231
|
version: '0'
|
232
232
|
type: :development
|
233
233
|
prerelease: false
|
234
234
|
version_requirements: !ruby/object:Gem::Requirement
|
235
235
|
requirements:
|
236
|
-
- -
|
236
|
+
- - ">="
|
237
237
|
- !ruby/object:Gem::Version
|
238
238
|
version: '0'
|
239
239
|
- !ruby/object:Gem::Dependency
|
240
240
|
name: webmock
|
241
241
|
requirement: !ruby/object:Gem::Requirement
|
242
242
|
requirements:
|
243
|
-
- -
|
243
|
+
- - ">="
|
244
244
|
- !ruby/object:Gem::Version
|
245
245
|
version: '0'
|
246
246
|
type: :development
|
247
247
|
prerelease: false
|
248
248
|
version_requirements: !ruby/object:Gem::Requirement
|
249
249
|
requirements:
|
250
|
-
- -
|
250
|
+
- - ">="
|
251
251
|
- !ruby/object:Gem::Version
|
252
252
|
version: '0'
|
253
253
|
description: ActiveFedora provides for creating and managing objects in the Fedora
|
@@ -260,10 +260,10 @@ extra_rdoc_files:
|
|
260
260
|
- LICENSE
|
261
261
|
- README.md
|
262
262
|
files:
|
263
|
-
- .gitignore
|
264
|
-
- .gitmodules
|
265
|
-
- .mailmap
|
266
|
-
- .travis.yml
|
263
|
+
- ".gitignore"
|
264
|
+
- ".gitmodules"
|
265
|
+
- ".mailmap"
|
266
|
+
- ".travis.yml"
|
267
267
|
- CONTRIBUTING.md
|
268
268
|
- CONTRIBUTORS.md
|
269
269
|
- Gemfile
|
@@ -313,6 +313,7 @@ files:
|
|
313
313
|
- lib/active_fedora/datastream_collections.rb
|
314
314
|
- lib/active_fedora/datastream_hash.rb
|
315
315
|
- lib/active_fedora/datastreams.rb
|
316
|
+
- lib/active_fedora/datastreams/nokogiri_datastreams.rb
|
316
317
|
- lib/active_fedora/digital_object.rb
|
317
318
|
- lib/active_fedora/fedora_attributes.rb
|
318
319
|
- lib/active_fedora/file_configurator.rb
|
@@ -527,17 +528,17 @@ require_paths:
|
|
527
528
|
- lib
|
528
529
|
required_ruby_version: !ruby/object:Gem::Requirement
|
529
530
|
requirements:
|
530
|
-
- -
|
531
|
+
- - ">="
|
531
532
|
- !ruby/object:Gem::Version
|
532
533
|
version: 1.9.3
|
533
534
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
534
535
|
requirements:
|
535
|
-
- -
|
536
|
+
- - ">"
|
536
537
|
- !ruby/object:Gem::Version
|
537
538
|
version: 1.3.1
|
538
539
|
requirements: []
|
539
540
|
rubyforge_project:
|
540
|
-
rubygems_version: 2.1
|
541
|
+
rubygems_version: 2.2.1
|
541
542
|
signing_key:
|
542
543
|
specification_version: 4
|
543
544
|
summary: A convenience libary for manipulating documents in the Fedora Repository.
|