active-fedora 6.8.0 → 7.0.0.pre1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (215) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +1 -0
  3. data/.travis.yml +15 -5
  4. data/CONTRIBUTING.md +2 -0
  5. data/Gemfile +0 -2
  6. data/History.txt +2 -32
  7. data/README.md +143 -0
  8. data/Rakefile +5 -7
  9. data/active-fedora.gemspec +9 -9
  10. data/gemfiles/rails3.gemfile +11 -0
  11. data/gemfiles/rails4.gemfile +10 -0
  12. data/lib/active_fedora.rb +31 -4
  13. data/lib/active_fedora/association_relation.rb +18 -0
  14. data/lib/active_fedora/associations.rb +38 -171
  15. data/lib/active_fedora/associations/association.rb +163 -0
  16. data/lib/active_fedora/associations/association_scope.rb +39 -0
  17. data/lib/active_fedora/associations/belongs_to_association.rb +47 -25
  18. data/lib/active_fedora/associations/builder/association.rb +55 -0
  19. data/lib/active_fedora/associations/builder/belongs_to.rb +100 -0
  20. data/lib/active_fedora/associations/builder/collection_association.rb +56 -0
  21. data/lib/active_fedora/associations/builder/has_and_belongs_to_many.rb +30 -0
  22. data/lib/active_fedora/associations/builder/has_many.rb +63 -0
  23. data/lib/active_fedora/associations/builder/singular_association.rb +32 -0
  24. data/lib/active_fedora/associations/{association_collection.rb → collection_association.rb} +203 -53
  25. data/lib/active_fedora/associations/collection_proxy.rb +862 -0
  26. data/lib/active_fedora/associations/has_and_belongs_to_many_association.rb +35 -25
  27. data/lib/active_fedora/associations/has_many_association.rb +36 -11
  28. data/lib/active_fedora/associations/singular_association.rb +62 -0
  29. data/lib/active_fedora/attributes.rb +43 -139
  30. data/lib/active_fedora/autosave_association.rb +317 -0
  31. data/lib/active_fedora/base.rb +10 -327
  32. data/lib/active_fedora/callbacks.rb +1 -3
  33. data/lib/active_fedora/content_model.rb +16 -0
  34. data/lib/active_fedora/core.rb +151 -0
  35. data/lib/active_fedora/datastream_attribute.rb +76 -0
  36. data/lib/active_fedora/datastream_hash.rb +8 -13
  37. data/lib/active_fedora/datastreams.rb +39 -26
  38. data/lib/active_fedora/digital_object.rb +2 -2
  39. data/lib/active_fedora/fedora_attributes.rb +45 -0
  40. data/lib/active_fedora/fixture_loader.rb +1 -1
  41. data/lib/active_fedora/indexing.rb +6 -1
  42. data/lib/active_fedora/model.rb +0 -17
  43. data/lib/active_fedora/nested_attributes.rb +2 -2
  44. data/lib/active_fedora/null_relation.rb +7 -0
  45. data/lib/active_fedora/om_datastream.rb +3 -4
  46. data/lib/active_fedora/persistence.rb +41 -29
  47. data/lib/active_fedora/querying.rb +2 -163
  48. data/lib/active_fedora/rdf.rb +1 -0
  49. data/lib/active_fedora/rdf/indexing.rb +67 -0
  50. data/lib/active_fedora/rdf_datastream.rb +2 -50
  51. data/lib/active_fedora/rdf_node.rb +12 -7
  52. data/lib/active_fedora/rdf_node/term_proxy.rb +30 -21
  53. data/lib/active_fedora/rdfxml_rdf_datastream.rb +1 -1
  54. data/lib/active_fedora/reflection.rb +163 -20
  55. data/lib/active_fedora/relation.rb +33 -130
  56. data/lib/active_fedora/relation/calculations.rb +19 -0
  57. data/lib/active_fedora/relation/delegation.rb +22 -0
  58. data/lib/active_fedora/relation/finder_methods.rb +247 -0
  59. data/lib/active_fedora/relation/merger.rb +22 -0
  60. data/lib/active_fedora/relation/query_methods.rb +58 -0
  61. data/lib/active_fedora/relation/spawn_methods.rb +46 -0
  62. data/lib/active_fedora/relationship_graph.rb +0 -2
  63. data/lib/active_fedora/rels_ext_datastream.rb +1 -4
  64. data/lib/active_fedora/rubydora_connection.rb +1 -1
  65. data/lib/active_fedora/scoping.rb +20 -0
  66. data/lib/active_fedora/scoping/default.rb +38 -0
  67. data/lib/active_fedora/scoping/named.rb +32 -0
  68. data/lib/active_fedora/semantic_node.rb +54 -106
  69. data/lib/active_fedora/serialization.rb +19 -0
  70. data/lib/active_fedora/sharding.rb +58 -0
  71. data/lib/active_fedora/solr_digital_object.rb +15 -5
  72. data/lib/active_fedora/solr_instance_loader.rb +1 -1
  73. data/lib/active_fedora/solr_service.rb +1 -1
  74. data/lib/active_fedora/unsaved_digital_object.rb +6 -4
  75. data/lib/active_fedora/version.rb +1 -1
  76. data/lib/tasks/active_fedora.rake +3 -0
  77. data/lib/tasks/active_fedora_dev.rake +6 -5
  78. data/spec/config_helper.rb +14 -14
  79. data/spec/integration/associations_spec.rb +168 -455
  80. data/spec/integration/attributes_spec.rb +12 -11
  81. data/spec/integration/auditable_spec.rb +11 -11
  82. data/spec/integration/autosave_association_spec.rb +25 -0
  83. data/spec/integration/base_spec.rb +163 -163
  84. data/spec/integration/belongs_to_association_spec.rb +166 -0
  85. data/spec/integration/bug_spec.rb +7 -7
  86. data/spec/integration/collection_association_spec.rb +58 -0
  87. data/spec/integration/complex_rdf_datastream_spec.rb +88 -88
  88. data/spec/integration/datastream_collections_spec.rb +69 -69
  89. data/spec/integration/datastream_spec.rb +43 -43
  90. data/spec/integration/datastreams_spec.rb +63 -63
  91. data/spec/integration/delete_all_spec.rb +46 -39
  92. data/spec/integration/fedora_solr_sync_spec.rb +5 -5
  93. data/spec/integration/field_to_solr_name_spec.rb +34 -0
  94. data/spec/integration/full_featured_model_spec.rb +100 -101
  95. data/spec/integration/has_and_belongs_to_many_associations_spec.rb +341 -0
  96. data/spec/integration/has_many_associations_spec.rb +172 -24
  97. data/spec/integration/json_serialization_spec.rb +31 -0
  98. data/spec/integration/load_from_solr_spec.rb +48 -0
  99. data/spec/integration/model_spec.rb +35 -40
  100. data/spec/integration/nested_attribute_spec.rb +42 -43
  101. data/spec/integration/ntriples_datastream_spec.rb +131 -113
  102. data/spec/integration/om_datastream_spec.rb +67 -67
  103. data/spec/integration/persistence_spec.rb +7 -7
  104. data/spec/integration/rdf_nested_attributes_spec.rb +56 -56
  105. data/spec/integration/relation_delegation_spec.rb +26 -25
  106. data/spec/integration/relation_spec.rb +42 -0
  107. data/spec/integration/rels_ext_datastream_spec.rb +20 -20
  108. data/spec/integration/scoped_query_spec.rb +61 -51
  109. data/spec/integration/solr_instance_loader_spec.rb +5 -5
  110. data/spec/integration/solr_service_spec.rb +46 -46
  111. data/spec/samples/hydra-mods_article_datastream.rb +334 -334
  112. data/spec/samples/hydra-rights_metadata_datastream.rb +57 -57
  113. data/spec/samples/marpa-dc_datastream.rb +17 -17
  114. data/spec/samples/models/audio_record.rb +16 -16
  115. data/spec/samples/models/image.rb +2 -2
  116. data/spec/samples/models/mods_article.rb +5 -5
  117. data/spec/samples/models/oral_history.rb +18 -18
  118. data/spec/samples/models/seminar.rb +24 -24
  119. data/spec/samples/models/seminar_audio_file.rb +17 -17
  120. data/spec/samples/oral_history_sample_model.rb +21 -21
  121. data/spec/samples/special_thing.rb +14 -14
  122. data/spec/spec_helper.rb +11 -7
  123. data/spec/support/an_active_model.rb +2 -8
  124. data/spec/support/freeze_mocks.rb +12 -0
  125. data/spec/support/mock_fedora.rb +17 -16
  126. data/spec/unit/active_fedora_spec.rb +58 -60
  127. data/spec/unit/attributes_spec.rb +314 -0
  128. data/spec/unit/base_active_model_spec.rb +28 -27
  129. data/spec/unit/base_cma_spec.rb +5 -5
  130. data/spec/unit/base_datastream_management_spec.rb +27 -27
  131. data/spec/unit/base_extra_spec.rb +76 -48
  132. data/spec/unit/base_spec.rb +277 -348
  133. data/spec/unit/callback_spec.rb +18 -19
  134. data/spec/unit/code_configurator_spec.rb +17 -17
  135. data/spec/unit/config_spec.rb +8 -16
  136. data/spec/unit/content_model_spec.rb +79 -60
  137. data/spec/unit/datastream_collections_spec.rb +229 -229
  138. data/spec/unit/datastream_spec.rb +51 -63
  139. data/spec/unit/datastreams_spec.rb +87 -87
  140. data/spec/unit/file_configurator_spec.rb +217 -217
  141. data/spec/unit/has_and_belongs_to_many_collection_spec.rb +44 -25
  142. data/spec/unit/has_many_collection_spec.rb +26 -8
  143. data/spec/unit/inheritance_spec.rb +13 -12
  144. data/spec/unit/model_spec.rb +39 -45
  145. data/spec/unit/nom_datastream_spec.rb +15 -15
  146. data/spec/unit/ntriples_datastream_spec.rb +123 -118
  147. data/spec/unit/om_datastream_spec.rb +227 -233
  148. data/spec/unit/persistence_spec.rb +34 -15
  149. data/spec/unit/predicates_spec.rb +73 -73
  150. data/spec/unit/property_spec.rb +17 -9
  151. data/spec/unit/qualified_dublin_core_datastream_spec.rb +33 -33
  152. data/spec/unit/query_spec.rb +222 -198
  153. data/spec/unit/rdf_datastream_spec.rb +21 -28
  154. data/spec/unit/rdf_list_nested_attributes_spec.rb +34 -34
  155. data/spec/unit/rdf_list_spec.rb +65 -64
  156. data/spec/unit/rdf_node_spec.rb +7 -7
  157. data/spec/unit/rdf_xml_writer_spec.rb +10 -10
  158. data/spec/unit/rdfxml_rdf_datastream_spec.rb +27 -27
  159. data/spec/unit/relationship_graph_spec.rb +51 -51
  160. data/spec/unit/rels_ext_datastream_spec.rb +68 -74
  161. data/spec/unit/rspec_matchers/belong_to_associated_active_fedora_object_matcher_spec.rb +15 -15
  162. data/spec/unit/rspec_matchers/have_many_associated_active_fedora_objects_matcher_spec.rb +15 -15
  163. data/spec/unit/rspec_matchers/have_predicate_matcher_spec.rb +15 -15
  164. data/spec/unit/rspec_matchers/match_fedora_datastream_matcher_spec.rb +12 -12
  165. data/spec/unit/rubydora_connection_spec.rb +5 -5
  166. data/spec/unit/semantic_node_spec.rb +48 -107
  167. data/spec/unit/serializers_spec.rb +4 -4
  168. data/spec/unit/service_definitions_spec.rb +26 -26
  169. data/spec/unit/simple_datastream_spec.rb +17 -17
  170. data/spec/unit/solr_config_options_spec.rb +29 -28
  171. data/spec/unit/solr_digital_object_spec.rb +17 -25
  172. data/spec/unit/solr_service_spec.rb +95 -82
  173. data/spec/unit/unsaved_digital_object_spec.rb +24 -23
  174. data/spec/unit/validations_spec.rb +21 -21
  175. metadata +110 -159
  176. data/.rspec +0 -1
  177. data/.rubocop.yml +0 -1
  178. data/.rubocop_todo.yml +0 -938
  179. data/CONSOLE_GETTING_STARTED.textile +0 -1
  180. data/NOKOGIRI_DATASTREAMS.textile +0 -1
  181. data/README.textile +0 -116
  182. data/lib/active_fedora/associations/association_proxy.rb +0 -178
  183. data/lib/active_fedora/delegating.rb +0 -72
  184. data/lib/active_fedora/nokogiri_datastream.rb +0 -11
  185. data/spec/integration/delegating_spec.rb +0 -59
  186. data/spec/rails3_test_app/.gitignore +0 -4
  187. data/spec/rails3_test_app/.rspec +0 -1
  188. data/spec/rails3_test_app/Gemfile +0 -40
  189. data/spec/rails3_test_app/Rakefile +0 -7
  190. data/spec/rails3_test_app/app/controllers/application_controller.rb +0 -3
  191. data/spec/rails3_test_app/app/helpers/application_helper.rb +0 -2
  192. data/spec/rails3_test_app/app/views/layouts/application.html.erb +0 -14
  193. data/spec/rails3_test_app/config.ru +0 -4
  194. data/spec/rails3_test_app/config/application.rb +0 -42
  195. data/spec/rails3_test_app/config/boot.rb +0 -6
  196. data/spec/rails3_test_app/config/database.yml +0 -22
  197. data/spec/rails3_test_app/config/environment.rb +0 -5
  198. data/spec/rails3_test_app/config/environments/development.rb +0 -25
  199. data/spec/rails3_test_app/config/environments/production.rb +0 -49
  200. data/spec/rails3_test_app/config/environments/test.rb +0 -35
  201. data/spec/rails3_test_app/config/initializers/backtrace_silencers.rb +0 -7
  202. data/spec/rails3_test_app/config/initializers/inflections.rb +0 -10
  203. data/spec/rails3_test_app/config/initializers/mime_types.rb +0 -5
  204. data/spec/rails3_test_app/config/initializers/secret_token.rb +0 -7
  205. data/spec/rails3_test_app/config/initializers/session_store.rb +0 -8
  206. data/spec/rails3_test_app/config/locales/en.yml +0 -5
  207. data/spec/rails3_test_app/config/routes.rb +0 -58
  208. data/spec/rails3_test_app/db/seeds.rb +0 -7
  209. data/spec/rails3_test_app/run_tests +0 -3
  210. data/spec/rails3_test_app/script/rails +0 -6
  211. data/spec/rails3_test_app/spec/spec_helper.rb +0 -27
  212. data/spec/rails3_test_app/spec/unit/rails_3_init.rb +0 -15
  213. data/spec/unit/association_proxy_spec.rb +0 -12
  214. data/spec/unit/base_delegate_spec.rb +0 -197
  215. data/spec/unit/base_delegate_to_spec.rb +0 -73
@@ -1,46 +1,47 @@
1
1
  require 'spec_helper'
2
2
 
3
3
  describe ActiveFedora::UnsavedDigitalObject do
4
+
5
+ describe "an unsaved instance" do
6
+ subject { ActiveFedora::UnsavedDigitalObject.new(ActiveFedora::Base, 'bar') }
4
7
 
5
- describe 'an unsaved instance' do
6
- before do
7
- @obj = ActiveFedora::UnsavedDigitalObject.new(ActiveFedora::Base, 'bar')
8
- end
9
- it 'should have ownerId property' do
10
- @obj.ownerId = 'fooo'
11
- expect(@obj.ownerId).to eq('fooo')
8
+ it { should be_new_record}
9
+
10
+ it "should have ownerId property" do
11
+ subject.ownerId = 'fooo'
12
+ subject.ownerId.should == 'fooo'
12
13
  end
13
14
 
14
- it 'should have state' do
15
- @obj.ownerId = 'D'
16
- expect(@obj.ownerId).to eq('D')
15
+ it "should have state" do
16
+ subject.ownerId = 'D'
17
+ subject.ownerId.should == 'D'
17
18
  end
18
19
 
19
- it 'should not have a default pid' do
20
- expect(@obj.pid).to be_nil
20
+ it "should not have a default pid" do
21
+ subject.pid.should be_nil
21
22
  end
22
- it 'should be able to set the pid' do
23
- @obj.pid = 'my:new_object'
24
- expect(@obj.pid).to eq('my:new_object')
23
+ it "should be able to set the pid" do
24
+ subject.pid = "my:new_object"
25
+ subject.pid.should == "my:new_object"
25
26
  end
26
27
  end
27
28
 
28
29
 
29
- describe '#save' do
30
+ describe "#save" do
30
31
  before :all do
31
- obj = ActiveFedora::UnsavedDigitalObject.new(ActiveFedora::Base, 'bar')
32
+ obj = ActiveFedora::UnsavedDigitalObject.new(ActiveFedora::Base, 'bar')
32
33
  obj.label = 'my label'
33
34
  obj.ownerId = 'fooo'
34
35
  @saved_obj = obj.save
35
36
  end
36
- it 'should be a digital object' do
37
- expect(@saved_obj).to be_kind_of ActiveFedora::DigitalObject
37
+ it "should be a digital object" do
38
+ @saved_obj.should be_kind_of ActiveFedora::DigitalObject
38
39
  end
39
- it 'should set the ownerId property' do
40
- expect(@saved_obj.ownerId).to eq('fooo')
40
+ it "should set the ownerId property" do
41
+ @saved_obj.ownerId.should == 'fooo'
41
42
  end
42
- it 'should set the label property' do
43
- expect(@saved_obj.label).to eq('my label')
43
+ it "should set the label property" do
44
+ @saved_obj.label.should == 'my label'
44
45
  end
45
46
  end
46
47
 
@@ -3,16 +3,16 @@ require 'spec_helper'
3
3
  describe ActiveFedora::Base do
4
4
  before :all do
5
5
  class ValidationStub < ActiveFedora::Base
6
- has_metadata :type => ActiveFedora::SimpleDatastream, :name => 'someData' do |m|
7
- m.field 'fubar', :string
8
- m.field 'swank', :text
6
+ has_metadata :type=>ActiveFedora::SimpleDatastream, :name=>"someData" do |m|
7
+ m.field "fubar", :string
8
+ m.field "swank", :text
9
9
  end
10
- delegate :fubar, :to => 'someData', multiple: true
11
- delegate :swank, :to => 'someData', multiple: false
10
+ has_attributes :fubar, datastream: 'someData', multiple: true
11
+ has_attributes :swank, datastream: 'someData', multiple: false
12
12
 
13
13
  validates_presence_of :fubar
14
- validates_length_of :swank, :minimum => 5
15
-
14
+ validates_length_of :swank, :minimum=>5
15
+
16
16
  end
17
17
  end
18
18
 
@@ -22,28 +22,28 @@ describe ActiveFedora::Base do
22
22
  Object.send(:remove_const, :ValidationStub)
23
23
  end
24
24
 
25
- describe 'a valid object' do
25
+ describe "a valid object" do
26
26
  before do
27
- subject.attributes = { fubar: 'here', swank: 'long enough'}
27
+ subject.attributes={ fubar:'here', swank:'long enough'}
28
28
  end
29
-
30
- it { is_expected.to be_valid}
29
+
30
+ it { should be_valid}
31
31
  end
32
- describe 'an invalid object' do
32
+ describe "an invalid object" do
33
33
  before do
34
- subject.attributes = { swank: 'smal'}
34
+ subject.attributes={ swank:'smal'}
35
35
  end
36
- it 'should have errors' do
37
- expect(subject).not_to be_valid
38
- expect(subject.errors[:fubar]).to eq(["can't be blank"])
39
- expect(subject.errors[:swank]).to eq(['is too short (minimum is 5 characters)'])
36
+ it "should have errors" do
37
+ subject.should_not be_valid
38
+ subject.errors[:fubar].should == ["can't be blank"]
39
+ subject.errors[:swank].should == ["is too short (minimum is 5 characters)"]
40
40
  end
41
41
  end
42
42
 
43
- describe 'required terms' do
44
- it 'should be required' do
45
- expect(subject.required?(:fubar)).to be_truthy
46
- expect(subject.required?(:swank)).to be_falsey
43
+ describe "required terms" do
44
+ it "should be required" do
45
+ subject.required?(:fubar).should be_true
46
+ subject.required?(:swank).should be_false
47
47
  end
48
48
  end
49
49
 
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: 6.8.0
4
+ version: 7.0.0.pre1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Zumwalt
@@ -10,270 +10,244 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2016-10-13 00:00:00.000000000 Z
13
+ date: 2014-01-13 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: '0'
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: '0'
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
- version: '3.0'
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
- version: '3.0'
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
- version: '3'
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
- version: '3'
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
- version: '1.6'
92
- - - ">="
93
- - !ruby/object:Gem::Version
94
- version: 1.6.5
91
+ version: 1.7.0.pre1
95
92
  type: :runtime
96
93
  prerelease: false
97
94
  version_requirements: !ruby/object:Gem::Requirement
98
95
  requirements:
99
- - - "~>"
100
- - !ruby/object:Gem::Version
101
- version: '1.6'
102
- - - ">="
96
+ - - ~>
103
97
  - !ruby/object:Gem::Version
104
- version: 1.6.5
98
+ version: 1.7.0.pre1
105
99
  - !ruby/object:Gem::Dependency
106
100
  name: rdf
107
101
  requirement: !ruby/object:Gem::Requirement
108
102
  requirements:
109
- - - "~>"
110
- - !ruby/object:Gem::Version
111
- version: '1.1'
112
- - - ">="
103
+ - - '>='
113
104
  - !ruby/object:Gem::Version
114
- version: 1.1.1.1
105
+ version: '0'
115
106
  type: :runtime
116
107
  prerelease: false
117
108
  version_requirements: !ruby/object:Gem::Requirement
118
109
  requirements:
119
- - - "~>"
120
- - !ruby/object:Gem::Version
121
- version: '1.1'
122
- - - ">="
110
+ - - '>='
123
111
  - !ruby/object:Gem::Version
124
- version: 1.1.1.1
112
+ version: '0'
125
113
  - !ruby/object:Gem::Dependency
126
114
  name: rdf-rdfxml
127
115
  requirement: !ruby/object:Gem::Requirement
128
116
  requirements:
129
- - - "~>"
117
+ - - ~>
130
118
  - !ruby/object:Gem::Version
131
- version: '1.1'
119
+ version: 1.1.0
132
120
  type: :runtime
133
121
  prerelease: false
134
122
  version_requirements: !ruby/object:Gem::Requirement
135
123
  requirements:
136
- - - "~>"
124
+ - - ~>
137
125
  - !ruby/object:Gem::Version
138
- version: '1.1'
126
+ version: 1.1.0
139
127
  - !ruby/object:Gem::Dependency
140
128
  name: deprecation
141
129
  requirement: !ruby/object:Gem::Requirement
142
130
  requirements:
143
- - - ">="
131
+ - - '>='
144
132
  - !ruby/object:Gem::Version
145
133
  version: '0'
146
134
  type: :runtime
147
135
  prerelease: false
148
136
  version_requirements: !ruby/object:Gem::Requirement
149
137
  requirements:
150
- - - ">="
138
+ - - '>='
151
139
  - !ruby/object:Gem::Version
152
140
  version: '0'
153
141
  - !ruby/object:Gem::Dependency
154
142
  name: rdoc
155
143
  requirement: !ruby/object:Gem::Requirement
156
144
  requirements:
157
- - - ">="
145
+ - - '>='
158
146
  - !ruby/object:Gem::Version
159
147
  version: '0'
160
148
  type: :development
161
149
  prerelease: false
162
150
  version_requirements: !ruby/object:Gem::Requirement
163
151
  requirements:
164
- - - ">="
152
+ - - '>='
165
153
  - !ruby/object:Gem::Version
166
154
  version: '0'
167
155
  - !ruby/object:Gem::Dependency
168
156
  name: yard
169
157
  requirement: !ruby/object:Gem::Requirement
170
158
  requirements:
171
- - - ">="
172
- - !ruby/object:Gem::Version
173
- version: '0'
174
- type: :development
175
- prerelease: false
176
- version_requirements: !ruby/object:Gem::Requirement
177
- requirements:
178
- - - ">="
179
- - !ruby/object:Gem::Version
180
- version: '0'
181
- - !ruby/object:Gem::Dependency
182
- name: RedCloth
183
- requirement: !ruby/object:Gem::Requirement
184
- requirements:
185
- - - ">="
159
+ - - '>='
186
160
  - !ruby/object:Gem::Version
187
161
  version: '0'
188
162
  type: :development
189
163
  prerelease: false
190
164
  version_requirements: !ruby/object:Gem::Requirement
191
165
  requirements:
192
- - - ">="
166
+ - - '>='
193
167
  - !ruby/object:Gem::Version
194
168
  version: '0'
195
169
  - !ruby/object:Gem::Dependency
196
170
  name: rake
197
171
  requirement: !ruby/object:Gem::Requirement
198
172
  requirements:
199
- - - ">="
173
+ - - '>='
200
174
  - !ruby/object:Gem::Version
201
175
  version: '0'
202
176
  type: :development
203
177
  prerelease: false
204
178
  version_requirements: !ruby/object:Gem::Requirement
205
179
  requirements:
206
- - - ">="
180
+ - - '>='
207
181
  - !ruby/object:Gem::Version
208
182
  version: '0'
209
183
  - !ruby/object:Gem::Dependency
210
184
  name: jettywrapper
211
185
  requirement: !ruby/object:Gem::Requirement
212
186
  requirements:
213
- - - ">="
187
+ - - '>='
214
188
  - !ruby/object:Gem::Version
215
189
  version: 1.4.0
216
190
  type: :development
217
191
  prerelease: false
218
192
  version_requirements: !ruby/object:Gem::Requirement
219
193
  requirements:
220
- - - ">="
194
+ - - '>='
221
195
  - !ruby/object:Gem::Version
222
196
  version: 1.4.0
223
197
  - !ruby/object:Gem::Dependency
224
198
  name: rspec
225
199
  requirement: !ruby/object:Gem::Requirement
226
200
  requirements:
227
- - - "~>"
201
+ - - '>='
228
202
  - !ruby/object:Gem::Version
229
- version: '2.99'
203
+ version: 2.9.0
230
204
  type: :development
231
205
  prerelease: false
232
206
  version_requirements: !ruby/object:Gem::Requirement
233
207
  requirements:
234
- - - "~>"
208
+ - - '>='
235
209
  - !ruby/object:Gem::Version
236
- version: '2.99'
210
+ version: 2.9.0
237
211
  - !ruby/object:Gem::Dependency
238
212
  name: equivalent-xml
239
213
  requirement: !ruby/object:Gem::Requirement
240
214
  requirements:
241
- - - ">="
215
+ - - '>='
242
216
  - !ruby/object:Gem::Version
243
217
  version: '0'
244
218
  type: :development
245
219
  prerelease: false
246
220
  version_requirements: !ruby/object:Gem::Requirement
247
221
  requirements:
248
- - - ">="
222
+ - - '>='
249
223
  - !ruby/object:Gem::Version
250
224
  version: '0'
251
225
  - !ruby/object:Gem::Dependency
252
226
  name: rest-client
253
227
  requirement: !ruby/object:Gem::Requirement
254
228
  requirements:
255
- - - ">="
229
+ - - '>='
256
230
  - !ruby/object:Gem::Version
257
231
  version: '0'
258
232
  type: :development
259
233
  prerelease: false
260
234
  version_requirements: !ruby/object:Gem::Requirement
261
235
  requirements:
262
- - - ">="
236
+ - - '>='
263
237
  - !ruby/object:Gem::Version
264
238
  version: '0'
265
239
  - !ruby/object:Gem::Dependency
266
240
  name: webmock
267
241
  requirement: !ruby/object:Gem::Requirement
268
242
  requirements:
269
- - - ">="
243
+ - - '>='
270
244
  - !ruby/object:Gem::Version
271
245
  version: '0'
272
246
  type: :development
273
247
  prerelease: false
274
248
  version_requirements: !ruby/object:Gem::Requirement
275
249
  requirements:
276
- - - ">="
250
+ - - '>='
277
251
  - !ruby/object:Gem::Version
278
252
  version: '0'
279
253
  description: ActiveFedora provides for creating and managing objects in the Fedora
@@ -284,23 +258,18 @@ executables: []
284
258
  extensions: []
285
259
  extra_rdoc_files:
286
260
  - LICENSE
287
- - README.textile
261
+ - README.md
288
262
  files:
289
- - ".gitignore"
290
- - ".gitmodules"
291
- - ".mailmap"
292
- - ".rspec"
293
- - ".rubocop.yml"
294
- - ".rubocop_todo.yml"
295
- - ".travis.yml"
296
- - CONSOLE_GETTING_STARTED.textile
263
+ - .gitignore
264
+ - .gitmodules
265
+ - .mailmap
266
+ - .travis.yml
297
267
  - CONTRIBUTING.md
298
268
  - CONTRIBUTORS.md
299
269
  - Gemfile
300
270
  - History.txt
301
271
  - LICENSE
302
- - NOKOGIRI_DATASTREAMS.textile
303
- - README.textile
272
+ - README.md
304
273
  - Rakefile
305
274
  - active-fedora.gemspec
306
275
  - config/fedora.yml
@@ -310,27 +279,42 @@ files:
310
279
  - config/solr.yml
311
280
  - config/solr_mappings_af_0.1.yml
312
281
  - config/solr_mappings_bl_2.4.yml
282
+ - gemfiles/rails3.gemfile
283
+ - gemfiles/rails4.gemfile
313
284
  - lib/active-fedora.rb
314
285
  - lib/active_fedora.rb
286
+ - lib/active_fedora/association_relation.rb
315
287
  - lib/active_fedora/associations.rb
316
- - lib/active_fedora/associations/association_collection.rb
317
- - lib/active_fedora/associations/association_proxy.rb
288
+ - lib/active_fedora/associations/association.rb
289
+ - lib/active_fedora/associations/association_scope.rb
318
290
  - lib/active_fedora/associations/belongs_to_association.rb
291
+ - lib/active_fedora/associations/builder/association.rb
292
+ - lib/active_fedora/associations/builder/belongs_to.rb
293
+ - lib/active_fedora/associations/builder/collection_association.rb
294
+ - lib/active_fedora/associations/builder/has_and_belongs_to_many.rb
295
+ - lib/active_fedora/associations/builder/has_many.rb
296
+ - lib/active_fedora/associations/builder/singular_association.rb
297
+ - lib/active_fedora/associations/collection_association.rb
298
+ - lib/active_fedora/associations/collection_proxy.rb
319
299
  - lib/active_fedora/associations/has_and_belongs_to_many_association.rb
320
300
  - lib/active_fedora/associations/has_many_association.rb
301
+ - lib/active_fedora/associations/singular_association.rb
321
302
  - lib/active_fedora/attributes.rb
322
303
  - lib/active_fedora/attributes/serializers.rb
323
304
  - lib/active_fedora/auditable.rb
305
+ - lib/active_fedora/autosave_association.rb
324
306
  - lib/active_fedora/base.rb
325
307
  - lib/active_fedora/callbacks.rb
326
308
  - lib/active_fedora/config.rb
327
309
  - lib/active_fedora/content_model.rb
310
+ - lib/active_fedora/core.rb
328
311
  - lib/active_fedora/datastream.rb
312
+ - lib/active_fedora/datastream_attribute.rb
329
313
  - lib/active_fedora/datastream_collections.rb
330
314
  - lib/active_fedora/datastream_hash.rb
331
315
  - lib/active_fedora/datastreams.rb
332
- - lib/active_fedora/delegating.rb
333
316
  - lib/active_fedora/digital_object.rb
317
+ - lib/active_fedora/fedora_attributes.rb
334
318
  - lib/active_fedora/file_configurator.rb
335
319
  - lib/active_fedora/fixture_exporter.rb
336
320
  - lib/active_fedora/fixture_loader.rb
@@ -338,9 +322,9 @@ files:
338
322
  - lib/active_fedora/locale/en.yml
339
323
  - lib/active_fedora/model.rb
340
324
  - lib/active_fedora/nested_attributes.rb
341
- - lib/active_fedora/nokogiri_datastream.rb
342
325
  - lib/active_fedora/nom_datastream.rb
343
326
  - lib/active_fedora/ntriples_rdf_datastream.rb
327
+ - lib/active_fedora/null_relation.rb
344
328
  - lib/active_fedora/om_datastream.rb
345
329
  - lib/active_fedora/persistence.rb
346
330
  - lib/active_fedora/predicates.rb
@@ -349,6 +333,7 @@ files:
349
333
  - lib/active_fedora/querying.rb
350
334
  - lib/active_fedora/railtie.rb
351
335
  - lib/active_fedora/rdf.rb
336
+ - lib/active_fedora/rdf/indexing.rb
352
337
  - lib/active_fedora/rdf/nested_attributes.rb
353
338
  - lib/active_fedora/rdf/node_config.rb
354
339
  - lib/active_fedora/rdf_datastream.rb
@@ -360,6 +345,12 @@ files:
360
345
  - lib/active_fedora/rdfxml_rdf_datastream.rb
361
346
  - lib/active_fedora/reflection.rb
362
347
  - lib/active_fedora/relation.rb
348
+ - lib/active_fedora/relation/calculations.rb
349
+ - lib/active_fedora/relation/delegation.rb
350
+ - lib/active_fedora/relation/finder_methods.rb
351
+ - lib/active_fedora/relation/merger.rb
352
+ - lib/active_fedora/relation/query_methods.rb
353
+ - lib/active_fedora/relation/spawn_methods.rb
363
354
  - lib/active_fedora/relationship_graph.rb
364
355
  - lib/active_fedora/rels_ext_datastream.rb
365
356
  - lib/active_fedora/rspec_matchers.rb
@@ -368,8 +359,13 @@ files:
368
359
  - lib/active_fedora/rspec_matchers/have_predicate_matcher.rb
369
360
  - lib/active_fedora/rspec_matchers/match_fedora_datastream_matcher.rb
370
361
  - lib/active_fedora/rubydora_connection.rb
362
+ - lib/active_fedora/scoping.rb
363
+ - lib/active_fedora/scoping/default.rb
364
+ - lib/active_fedora/scoping/named.rb
371
365
  - lib/active_fedora/semantic_node.rb
366
+ - lib/active_fedora/serialization.rb
372
367
  - lib/active_fedora/service_definitions.rb
368
+ - lib/active_fedora/sharding.rb
373
369
  - lib/active_fedora/simple_datastream.rb
374
370
  - lib/active_fedora/solr_digital_object.rb
375
371
  - lib/active_fedora/solr_instance_loader.rb
@@ -422,17 +418,23 @@ files:
422
418
  - spec/integration/associations_spec.rb
423
419
  - spec/integration/attributes_spec.rb
424
420
  - spec/integration/auditable_spec.rb
421
+ - spec/integration/autosave_association_spec.rb
425
422
  - spec/integration/base_spec.rb
423
+ - spec/integration/belongs_to_association_spec.rb
426
424
  - spec/integration/bug_spec.rb
425
+ - spec/integration/collection_association_spec.rb
427
426
  - spec/integration/complex_rdf_datastream_spec.rb
428
427
  - spec/integration/datastream_collections_spec.rb
429
428
  - spec/integration/datastream_spec.rb
430
429
  - spec/integration/datastreams_spec.rb
431
- - spec/integration/delegating_spec.rb
432
430
  - spec/integration/delete_all_spec.rb
433
431
  - spec/integration/fedora_solr_sync_spec.rb
432
+ - spec/integration/field_to_solr_name_spec.rb
434
433
  - spec/integration/full_featured_model_spec.rb
434
+ - spec/integration/has_and_belongs_to_many_associations_spec.rb
435
435
  - spec/integration/has_many_associations_spec.rb
436
+ - spec/integration/json_serialization_spec.rb
437
+ - spec/integration/load_from_solr_spec.rb
436
438
  - spec/integration/model_spec.rb
437
439
  - spec/integration/nested_attribute_spec.rb
438
440
  - spec/integration/ntriples_datastream_spec.rb
@@ -440,39 +442,11 @@ files:
440
442
  - spec/integration/persistence_spec.rb
441
443
  - spec/integration/rdf_nested_attributes_spec.rb
442
444
  - spec/integration/relation_delegation_spec.rb
445
+ - spec/integration/relation_spec.rb
443
446
  - spec/integration/rels_ext_datastream_spec.rb
444
447
  - spec/integration/scoped_query_spec.rb
445
448
  - spec/integration/solr_instance_loader_spec.rb
446
449
  - spec/integration/solr_service_spec.rb
447
- - spec/rails3_test_app/.gitignore
448
- - spec/rails3_test_app/.rspec
449
- - spec/rails3_test_app/.rvmrc
450
- - spec/rails3_test_app/Gemfile
451
- - spec/rails3_test_app/Gemfile.lock
452
- - spec/rails3_test_app/Rakefile
453
- - spec/rails3_test_app/app/controllers/application_controller.rb
454
- - spec/rails3_test_app/app/helpers/application_helper.rb
455
- - spec/rails3_test_app/app/views/layouts/application.html.erb
456
- - spec/rails3_test_app/config.ru
457
- - spec/rails3_test_app/config/application.rb
458
- - spec/rails3_test_app/config/boot.rb
459
- - spec/rails3_test_app/config/database.yml
460
- - spec/rails3_test_app/config/environment.rb
461
- - spec/rails3_test_app/config/environments/development.rb
462
- - spec/rails3_test_app/config/environments/production.rb
463
- - spec/rails3_test_app/config/environments/test.rb
464
- - spec/rails3_test_app/config/initializers/backtrace_silencers.rb
465
- - spec/rails3_test_app/config/initializers/inflections.rb
466
- - spec/rails3_test_app/config/initializers/mime_types.rb
467
- - spec/rails3_test_app/config/initializers/secret_token.rb
468
- - spec/rails3_test_app/config/initializers/session_store.rb
469
- - spec/rails3_test_app/config/locales/en.yml
470
- - spec/rails3_test_app/config/routes.rb
471
- - spec/rails3_test_app/db/seeds.rb
472
- - spec/rails3_test_app/run_tests
473
- - spec/rails3_test_app/script/rails
474
- - spec/rails3_test_app/spec/spec_helper.rb
475
- - spec/rails3_test_app/spec/unit/rails_3_init.rb
476
450
  - spec/rcov.opts
477
451
  - spec/samples/hydra-mods_article_datastream.rb
478
452
  - spec/samples/hydra-rights_metadata_datastream.rb
@@ -491,14 +465,13 @@ files:
491
465
  - spec/spec.opts
492
466
  - spec/spec_helper.rb
493
467
  - spec/support/an_active_model.rb
468
+ - spec/support/freeze_mocks.rb
494
469
  - spec/support/mock_fedora.rb
495
470
  - spec/unit/active_fedora_spec.rb
496
- - spec/unit/association_proxy_spec.rb
471
+ - spec/unit/attributes_spec.rb
497
472
  - spec/unit/base_active_model_spec.rb
498
473
  - spec/unit/base_cma_spec.rb
499
474
  - spec/unit/base_datastream_management_spec.rb
500
- - spec/unit/base_delegate_spec.rb
501
- - spec/unit/base_delegate_to_spec.rb
502
475
  - spec/unit/base_extra_spec.rb
503
476
  - spec/unit/base_spec.rb
504
477
  - spec/unit/callback_spec.rb
@@ -553,17 +526,17 @@ require_paths:
553
526
  - lib
554
527
  required_ruby_version: !ruby/object:Gem::Requirement
555
528
  requirements:
556
- - - ">="
529
+ - - '>='
557
530
  - !ruby/object:Gem::Version
558
531
  version: 1.9.3
559
532
  required_rubygems_version: !ruby/object:Gem::Requirement
560
533
  requirements:
561
- - - ">="
534
+ - - '>'
562
535
  - !ruby/object:Gem::Version
563
- version: '0'
536
+ version: 1.3.1
564
537
  requirements: []
565
538
  rubyforge_project:
566
- rubygems_version: 2.5.1
539
+ rubygems_version: 2.1.11
567
540
  signing_key:
568
541
  specification_version: 4
569
542
  summary: A convenience libary for manipulating documents in the Fedora Repository.
@@ -588,17 +561,23 @@ test_files:
588
561
  - spec/integration/associations_spec.rb
589
562
  - spec/integration/attributes_spec.rb
590
563
  - spec/integration/auditable_spec.rb
564
+ - spec/integration/autosave_association_spec.rb
591
565
  - spec/integration/base_spec.rb
566
+ - spec/integration/belongs_to_association_spec.rb
592
567
  - spec/integration/bug_spec.rb
568
+ - spec/integration/collection_association_spec.rb
593
569
  - spec/integration/complex_rdf_datastream_spec.rb
594
570
  - spec/integration/datastream_collections_spec.rb
595
571
  - spec/integration/datastream_spec.rb
596
572
  - spec/integration/datastreams_spec.rb
597
- - spec/integration/delegating_spec.rb
598
573
  - spec/integration/delete_all_spec.rb
599
574
  - spec/integration/fedora_solr_sync_spec.rb
575
+ - spec/integration/field_to_solr_name_spec.rb
600
576
  - spec/integration/full_featured_model_spec.rb
577
+ - spec/integration/has_and_belongs_to_many_associations_spec.rb
601
578
  - spec/integration/has_many_associations_spec.rb
579
+ - spec/integration/json_serialization_spec.rb
580
+ - spec/integration/load_from_solr_spec.rb
602
581
  - spec/integration/model_spec.rb
603
582
  - spec/integration/nested_attribute_spec.rb
604
583
  - spec/integration/ntriples_datastream_spec.rb
@@ -606,39 +585,11 @@ test_files:
606
585
  - spec/integration/persistence_spec.rb
607
586
  - spec/integration/rdf_nested_attributes_spec.rb
608
587
  - spec/integration/relation_delegation_spec.rb
588
+ - spec/integration/relation_spec.rb
609
589
  - spec/integration/rels_ext_datastream_spec.rb
610
590
  - spec/integration/scoped_query_spec.rb
611
591
  - spec/integration/solr_instance_loader_spec.rb
612
592
  - spec/integration/solr_service_spec.rb
613
- - spec/rails3_test_app/.gitignore
614
- - spec/rails3_test_app/.rspec
615
- - spec/rails3_test_app/.rvmrc
616
- - spec/rails3_test_app/Gemfile
617
- - spec/rails3_test_app/Gemfile.lock
618
- - spec/rails3_test_app/Rakefile
619
- - spec/rails3_test_app/app/controllers/application_controller.rb
620
- - spec/rails3_test_app/app/helpers/application_helper.rb
621
- - spec/rails3_test_app/app/views/layouts/application.html.erb
622
- - spec/rails3_test_app/config.ru
623
- - spec/rails3_test_app/config/application.rb
624
- - spec/rails3_test_app/config/boot.rb
625
- - spec/rails3_test_app/config/database.yml
626
- - spec/rails3_test_app/config/environment.rb
627
- - spec/rails3_test_app/config/environments/development.rb
628
- - spec/rails3_test_app/config/environments/production.rb
629
- - spec/rails3_test_app/config/environments/test.rb
630
- - spec/rails3_test_app/config/initializers/backtrace_silencers.rb
631
- - spec/rails3_test_app/config/initializers/inflections.rb
632
- - spec/rails3_test_app/config/initializers/mime_types.rb
633
- - spec/rails3_test_app/config/initializers/secret_token.rb
634
- - spec/rails3_test_app/config/initializers/session_store.rb
635
- - spec/rails3_test_app/config/locales/en.yml
636
- - spec/rails3_test_app/config/routes.rb
637
- - spec/rails3_test_app/db/seeds.rb
638
- - spec/rails3_test_app/run_tests
639
- - spec/rails3_test_app/script/rails
640
- - spec/rails3_test_app/spec/spec_helper.rb
641
- - spec/rails3_test_app/spec/unit/rails_3_init.rb
642
593
  - spec/rcov.opts
643
594
  - spec/samples/hydra-mods_article_datastream.rb
644
595
  - spec/samples/hydra-rights_metadata_datastream.rb
@@ -657,14 +608,13 @@ test_files:
657
608
  - spec/spec.opts
658
609
  - spec/spec_helper.rb
659
610
  - spec/support/an_active_model.rb
611
+ - spec/support/freeze_mocks.rb
660
612
  - spec/support/mock_fedora.rb
661
613
  - spec/unit/active_fedora_spec.rb
662
- - spec/unit/association_proxy_spec.rb
614
+ - spec/unit/attributes_spec.rb
663
615
  - spec/unit/base_active_model_spec.rb
664
616
  - spec/unit/base_cma_spec.rb
665
617
  - spec/unit/base_datastream_management_spec.rb
666
- - spec/unit/base_delegate_spec.rb
667
- - spec/unit/base_delegate_to_spec.rb
668
618
  - spec/unit/base_extra_spec.rb
669
619
  - spec/unit/base_spec.rb
670
620
  - spec/unit/callback_spec.rb
@@ -709,3 +659,4 @@ test_files:
709
659
  - spec/unit/solr_service_spec.rb
710
660
  - spec/unit/unsaved_digital_object_spec.rb
711
661
  - spec/unit/validations_spec.rb
662
+ has_rdoc: