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

(-)a/t/db_dependent/api/v1/password_validation.t (-4 / +9 lines)
Lines 136-142 subtest 'Password validation - authorized requests tests' => sub { Link Here
136
    };
136
    };
137
137
138
    $t->post_ok( "//$userid:$password@/api/v1/auth/password/validation" => json => $json )
138
    $t->post_ok( "//$userid:$password@/api/v1/auth/password/validation" => json => $json )
139
        ->status_is( 204, 'Validating using `cardnumber` works' )->content_is(q{});
139
        ->status_is( 201, 'Validating using `cardnumber` works' )
140
        ->json_is(
141
        { cardnumber => $librarian->cardnumber, patron_id => $librarian->id, userid => $librarian->userid } );
140
142
141
    $json = {
143
    $json = {
142
        identifier => $librarian->cardnumber,
144
        identifier => $librarian->cardnumber,
Lines 144-150 subtest 'Password validation - authorized requests tests' => sub { Link Here
144
    };
146
    };
145
147
146
    $t->post_ok( "//$userid:$password@/api/v1/auth/password/validation" => json => $json )
148
    $t->post_ok( "//$userid:$password@/api/v1/auth/password/validation" => json => $json )
147
        ->status_is( 204, 'Validating using `cardnumber` works' )->content_is(q{});
149
        ->status_is( 201, 'Validating using `cardnumber` works' )
150
        ->json_is(
151
        { cardnumber => $librarian->cardnumber, patron_id => $librarian->id, userid => $librarian->userid } );
148
152
149
    $json = {
153
    $json = {
150
        identifier => $deleted_cardnumber,
154
        identifier => $deleted_cardnumber,
Lines 178-184 subtest 'Password validation - authorized requests tests' => sub { Link Here
178
    };
182
    };
179
183
180
    $t->post_ok( "//$userid:$password@/api/v1/auth/password/validation" => json => $json )
184
    $t->post_ok( "//$userid:$password@/api/v1/auth/password/validation" => json => $json )
181
        ->status_is( 204, 'Validating using the `userid` attribute works' )->content_is(q{});
185
        ->status_is( 201, 'Validating using the `userid` attribute works' )
186
        ->json_is(
187
        { cardnumber => $librarian->cardnumber, patron_id => $librarian->id, userid => $librarian->userid } );
182
188
183
    $json = {
189
    $json = {
184
        identifier => $userid,
190
        identifier => $userid,
185
- 

Return to bug 34313