Permalink
Browse files

clean out add'l unapi references from tests (cc: pull request #10)

  • Loading branch information...
Chris Beer
Chris Beer committed Aug 8, 2011
1 parent a46defe commit 1ac03b83f009fe62e38fbee2095ce04b44ba10a8
@@ -83,10 +83,6 @@
page.should have_selector("link[rel=alternate][type='application/atom+xml']")
end
-Then /^I should see an unAPI discovery link/ do
- page.should have_selector("link[rel=unapi-server][type='application/xml']")
-end
-
Then /^I should see opensearch response metadata tags/ do
page.should have_selector("meta[name=totalResults]")
page.should have_selector("meta[name=startIndex]")
@@ -25,15 +25,6 @@ def path_to(page_name)
when /the facet page for "([^\"]*)"/
catalog_facet_path($1)
- when /the unAPI endpoint for "([^\"]+)" with format "([^\"]+)"/
- unapi_path(:id => $1, :format => $2)
-
- when /the unAPI endpoint for "([^\"]+)"/
- unapi_path(:id => $1)
-
- when /the unAPI endpoint/
- unapi_path
-
# Add more mappings here.
# Here is an example that pulls values out of the Regexp:
#
@@ -1,46 +0,0 @@
-# -*- encoding : utf-8 -*-
-require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper')
-
-describe "unAPI formats list" do
-
-
- before(:all) do
- class UnapiMockDocument
- include Blacklight::Solr::Document
- end
- module FakeExtension
- def self.extended(document)
- document.will_export_as(:mock, "application/mock")
- end
-
- def export_as_mock
- "mock_export"
- end
- end
-
- UnapiMockDocument.use_extension( FakeExtension )
- end
-
- it "should provide a list of object formats which should be supported for all documents" do
- @export_formats = { :mock => { :content_type => "application/mock" } }
- render :template => "catalog/unapi.xml.builder", :content_type => "application/mock"
- h = Hash.from_xml(rendered)
-
- h['formats'].should_not be_nil
- h['formats']['format'].should_not be_nil
- h['formats']['format']['name'].should == 'mock'
- h['formats']['format']['type'].should == 'application/mock'
- end
-
- it "should provide a list of object formats available from the unAPI service for the document" do
- @document = UnapiMockDocument.new({})
- @export_formats = @document.export_formats
- render :template => "catalog/unapi.xml.builder", :content_type => "application/mock"
- h = Hash.from_xml(rendered)
-
- h['formats'].should_not be_nil
- h['formats']['format'].should_not be_nil
- h['formats']['format']['name'].should == 'mock'
- h['formats']['format']['type'].should == 'application/mock'
- end
-end

0 comments on commit 1ac03b8

Please sign in to comment.