test/unit/primo_service_test.rb in umlaut-primo-0.1.2 vs test/unit/primo_service_test.rb in umlaut-primo-0.1.3
- old
+ new
@@ -199,10 +199,26 @@
assert_equal("#{@base_url}/primo_library/libweb/action/dlDisplay.do?docId=aleph000062856&institution=NYU&vid=#{@vid}", view_data[:url])
assert_equal(nil, view_data[:request_url])
assert_equal(ServiceResponse::MatchExact, view_data[:match_reliability])
end
+ test "expired dedupmgr record" do
+ request = requests(:digital_futures_living_in_a_dot_com_world)
+ VCR.use_cassette("digital_futures_living_in_a_dot_com_world", match_requests_on: [:body]) do
+ @primo_service.handle(request)
+ end
+
+ # Get latest from the DB after handling the service.
+ request.dispatched_services.reset
+ request.service_responses.reset
+
+ # Get the returned fulltext service responses
+ fulltexts = request.get_service_type('fulltext')
+
+ assert_not_empty(fulltexts)
+ end
+
test "sfx owner but fulltext empty" do
request = requests(:australian_journal_of_international_affairs_by_id)
VCR.use_cassette("australian journal of international affairs by id") do
@primo_service.handle(request)
end
@@ -253,6 +269,6 @@
assert_equal("Belgrad", request.referent.metadata["place"], "Publication place was not enhanced when resolving by ISSN.")
assert_equal("Filološki fakultet, Katedra za slavistiku", request.referent.metadata["pub"], "Publisher was not enhanced when resolving by ISSN.")
assert_equal("261559574", request.referent.metadata["oclcnum"], "OCLC number was not enhanced when resolving by ISSN.")
assert_equal("2008262508", request.referent.metadata["lccn"], "LCCN was not enhanced when resolving by ISSN.")
end
-end
\ No newline at end of file
+end