--- trunk/t/2-input.t 2007/02/04 12:37:42 795 +++ trunk/t/2-input.t 2007/02/04 12:42:43 796 @@ -11,6 +11,7 @@ BEGIN { use_ok( 'WebPAC::Input::ISIS' ); use_ok( 'WebPAC::Input::MARC' ); +use_ok( 'WebPAC::Input::Test' ); } my $debug = shift @ARGV; @@ -119,10 +120,25 @@ test_fetch($input, $input->size); # test modify_record -$module = 'WebPAC::Input::ISIS'; -ok($input = new WebPAC::Input( module => $module, no_log => $no_log, no_progress_bar => 1 ), "new $module"); +$module = 'WebPAC::Input::Test'; +ok($input = new WebPAC::Input( module => $module, no_log => $no_log, no_progress_bar => 1, debug => $debug ), "new $module"); ok($input->open( path => "$abs_path/modify_isis/LIBRI", ), "open modify_isis (plain)"); + +$WebPAC::Input::Test::rec = { + '200' => [ { + 'a' => 'foo', + 'b' => 'bar', + }, { + 'a' => 'baz', + } ], + '900' => [ + 'foobar', + ], +}; + +ok($input->size, 'size'); + ok(my $rec_p = $input->fetch, 'fetch'); # modify_records