root/WWW-OpenSearch/trunk.old/t/02_paginate.t

Revision 1609 (checked in by miyagawa, 15 years ago)

0.03: Fixed pagination

Line 
1 use strict;
2 use Test::More;
3
4 my $url = $ENV{OPENSEARCH_URL};
5 unless ($url) {
6     Test::More->import(skip_all => "OPENSEARCH_URL not set");
7     exit;
8 }
9
10 plan 'no_plan';
11
12 use WWW::OpenSearch;
13
14 my $engine = WWW::OpenSearch->new($url);
15 $engine->pager->entries_per_page(20);
16 $engine->pager->current_page(2);
17 my $query = $engine->setup_query("foo");
18 like $query, qr/page=2/, "page=2";
19
Note: See TracBrowser for help on using the browser.