projects
/
virtual-ldap
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
5c319ed
)
read configuration from koha-conf.xml
author
Dobrica Pavlinusic
<dpavlin@rot13.org>
Thu, 14 Jul 2011 18:49:24 +0000
(18:49 +0000)
committer
Dobrica Pavlinusic
<dpavlin@rot13.org>
Thu, 14 Jul 2011 18:49:24 +0000
(18:49 +0000)
t/koha/01-remove-test-user.t
patch
|
blob
|
history
diff --git
a/t/koha/01-remove-test-user.t
b/t/koha/01-remove-test-user.t
index
3f3a694
..
65d5418
100755
(executable)
--- a/
t/koha/01-remove-test-user.t
+++ b/
t/koha/01-remove-test-user.t
@@
-5,11
+5,18
@@
use strict;
use Test::More tests => 6;
use Test::WWW::Mechanize;
use Test::More tests => 6;
use Test::WWW::Mechanize;
+use XML::Simple;
+use Data::Dump qw(dump);
-
our ( $user, $passwd )
;
-
require 'config.p
l';
+
my $url = $ENV{INTRANET} || 'http://ffzg.koha-dev.rot13.org:8080'
;
+
my $koha_conf = $ENV{KOHA_CONF} || '/etc/koha/sites/ffzg/koha-conf.xm
l';
-my $url = 'https://localhost:8443'; # Koha intranet
+my $xml = XMLin( $koha_conf );
+diag 'Koha config = ',dump $xml->{config};
+
+our $config;
+require 't/config.pl';
+diag 'test config = ',dump $config;
my $mech = Test::WWW::Mechanize->new;
my $mech = Test::WWW::Mechanize->new;
@@
-17,10
+24,10
@@
$mech->get_ok( $url, 'intranet' );
$mech->submit_form_ok({
fields => {
$mech->submit_form_ok({
fields => {
- userid
=> $user
,
- password => $
passwd
,
+ userid
=> $xml->{config}->{user}
,
+ password => $
xml->{config}->{pass}
,
},
},
-},
'login'
);
+},
"login $xml->{config}->{user}"
);
$mech->submit_form_ok({
form_number => 2,
$mech->submit_form_ok({
form_number => 2,