From 1c3ba5b29669ff002ff9650535ec019f4022e1e1 Mon Sep 17 00:00:00 2001 From: franck cuny Date: Sun, 17 Oct 2010 21:46:03 +0200 Subject: update tests to use the dummy api, and replace api_base_url with base_url --- t/spore-middleware/format-xml.t | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 't/spore-middleware/format-xml.t') diff --git a/t/spore-middleware/format-xml.t b/t/spore-middleware/format-xml.t index 623e281..492f564 100644 --- a/t/spore-middleware/format-xml.t +++ b/t/spore-middleware/format-xml.t @@ -9,7 +9,7 @@ use Net::HTTP::Spore; my $content = { keys => [qw/1 2 3/] }; my $mock_server = { - '/test_spore/_all_docs' => sub { + '/show' => sub { my $req = shift; $req->new_response( 200, [ 'Content-Type' => 'text/xml' ], XMLout($content) ); @@ -17,13 +17,13 @@ my $mock_server = { }; ok my $client = - Net::HTTP::Spore->new_from_spec( 't/specs/couchdb.json', - api_base_url => 'http://localhost:5984' ); + Net::HTTP::Spore->new_from_spec( 't/specs/api.json', + base_url => 'http://localhost:5984' ); $client->enable('Format::XML'); $client->enable( 'Mock', tests => $mock_server ); -my $res = $client->get_all_documents( database => 'test_spore' ); +my $res = $client->get_info(); is $res->[0], 200; is_deeply $res->[2], $content; is $res->header('Content-Type'), 'text/xml'; -- cgit 1.4.1