spec/models/properties_datastream_spec.rb in sufia-1.3.0 vs spec/models/properties_datastream_spec.rb in sufia-2.0.0

- old
+ new

@@ -1,21 +1,22 @@ require 'spec_helper' describe PropertiesDatastream do - it "should have proxy_depositor" do - subject.proxy_depositor = 'kim@example.com' - subject.proxy_depositor.should == ['kim@example.com'] - subject.ng_xml.to_xml.should be_equivalent_to "<?xml version=\"1.0\"?><fields><proxyDepositor>kim@example.com</proxyDepositor></fields>" + + it "should have import_url" do + subject.import_url = 'http://example.com/somefile.txt' + subject.import_url.should == ['http://example.com/somefile.txt'] + subject.ng_xml.to_xml.should be_equivalent_to "<?xml version=\"1.0\"?><fields><importUrl>http://example.com/somefile.txt</importUrl></fields>" end describe "to_solr" do before do @doc = PropertiesDatastream.new.tap do |ds| - ds.proxy_depositor = 'kim@example.com' + ds.import_url = 'http://example.com/somefile.txt' end end subject { @doc.to_solr} - it "should have proxy_depositor" do - subject['proxy_depositor_ssim'].should == ['kim@example.com'] + it "should have import_url" do + subject['import_url_ssim'].should == ['http://example.com/somefile.txt'] end end end