View | Details | Raw Unified | Return to bug 13799
Collapse All | Expand All

(-)a/t/db_dependent/api/v1/borrowers.t (-5 / +4 lines)
Lines 46-55 my $borrower = $builder->build({ Link Here
46
    }
46
    }
47
});
47
});
48
48
49
$t->get_ok('/api/v1/borrowers')
49
$t->get_ok('/api/v1/patrons')
50
  ->status_is(403);
50
  ->status_is(403);
51
51
52
$t->get_ok("/api/v1/borrowers/" . $borrower->{ borrowernumber })
52
$t->get_ok("/api/v1/patrons/" . $borrower->{ borrowernumber })
53
  ->status_is(403);
53
  ->status_is(403);
54
54
55
my $loggedinuser = $builder->build({
55
my $loggedinuser = $builder->build({
Lines 68-80 $session->param('ip', '127.0.0.1'); Link Here
68
$session->param('lasttime', time());
68
$session->param('lasttime', time());
69
$session->flush;
69
$session->flush;
70
70
71
my $tx = $t->ua->build_tx(GET => '/api/v1/borrowers');
71
my $tx = $t->ua->build_tx(GET => '/api/v1/patrons');
72
$tx->req->cookies({name => 'CGISESSID', value => $session->id});
72
$tx->req->cookies({name => 'CGISESSID', value => $session->id});
73
$tx->req->env({REMOTE_ADDR => '127.0.0.1'});
73
$tx->req->env({REMOTE_ADDR => '127.0.0.1'});
74
$t->request_ok($tx)
74
$t->request_ok($tx)
75
  ->status_is(200);
75
  ->status_is(200);
76
76
77
$tx = $t->ua->build_tx(GET => "/api/v1/borrowers/" . $borrower->{ borrowernumber });
77
$tx = $t->ua->build_tx(GET => "/api/v1/patrons/" . $borrower->{ borrowernumber });
78
$tx->req->cookies({name => 'CGISESSID', value => $session->id});
78
$tx->req->cookies({name => 'CGISESSID', value => $session->id});
79
$t->request_ok($tx)
79
$t->request_ok($tx)
80
  ->status_is(200)
80
  ->status_is(200)
81
- 

Return to bug 13799