Bugzilla – Attachment 42434 Details for
Bug 14540
Move member-flags.pl to PermissionsManager to better manage permissions for testing.
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14540 - Followup regression test for bad login
Bug-14540---Followup-regression-test-for-bad-login.patch (text/plain), 2.01 KB, created by
Olli-Antti Kivilahti
on 2015-09-07 15:28:18 UTC
(
hide
)
Description:
Bug 14540 - Followup regression test for bad login
Filename:
MIME Type:
Creator:
Olli-Antti Kivilahti
Created:
2015-09-07 15:28:18 UTC
Size:
2.01 KB
patch
obsolete
>From 3ec4e0b1eedddd6a69b0c78a1976a6e2eec21dc8 Mon Sep 17 00:00:00 2001 >From: Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> >Date: Mon, 7 Sep 2015 18:15:22 +0300 >Subject: [PATCH] Bug 14540 - Followup regression test for bad login > >--- > t/db_dependent/Koha/Auth.t | 11 +++++++++++ > 1 file changed, 11 insertions(+) > >diff --git a/t/db_dependent/Koha/Auth.t b/t/db_dependent/Koha/Auth.t >index 51d3af2..ce50469 100644 >--- a/t/db_dependent/Koha/Auth.t >+++ b/t/db_dependent/Koha/Auth.t >@@ -29,6 +29,9 @@ use t::lib::Page::Opac::OpacMain; > > use t::lib::TestObjects::BorrowerFactory; > >+##Enable debug mode for PageObject tests. >+#$ENV{KOHA_PAGEOBJECT_DEBUG} = 1; >+ > ##Setting up the test context > my $testContext = {}; > >@@ -59,12 +62,14 @@ $permissionManager->grantPermission($borrowers->{'maxi_admin'}, 'superlibrarian' > eval { #run in a eval-block so we don't die without tearing down the test context > > my $mainpage = t::lib::Page::Mainpage->new(); >+ testBadPasswordLogin($mainpage); > testPasswordLoginLogout($mainpage); > testSuperuserPasswordLoginLogout($mainpage); > testSuperlibrarianPasswordLoginLogout($mainpage); > $mainpage->quit(); > > my $opacmain = t::lib::Page::Opac::OpacMain->new(); >+ testBadPasswordLogin($opacmain); > testOpacPasswordLoginLogout($opacmain); > testSuperuserPasswordLoginLogout($opacmain); > testOpacSuperlibrarianPasswordLoginLogout($opacmain); >@@ -88,6 +93,12 @@ sub tearDown { > ### STARTING TEST IMPLEMENTATIONS ### > ###################################################### > >+sub testBadPasswordLogin { >+ my ($mainpage) = @_; >+ $mainpage->isPasswordLoginAvailable()->failPasswordLogin($borrowers->{'1A01'}->userid(), 'a truly bad password') >+ ->refresh() #Refresh is important in bringing out certain bugs with cookies and misset Userid. >+ ->isPasswordLoginAvailable(); >+} > sub testPasswordLoginLogout { > my ($mainpage) = @_; > $mainpage->isPasswordLoginAvailable()->doPasswordLogin($borrowers->{'1A01'}->userid(), $password) >-- >1.9.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 14540
:
41030
|
41051
|
41055
|
41056
|
41059
|
41062
|
41071
|
41123
|
41158
|
41255
|
41258
|
41310
|
41402
|
41535
|
42390
|
42410
|
42432
|
42434
|
42550
|
44490
|
63252
|
63253
|
63254