Move session->env->getIp into session->request->address

This commit is contained in:
Colin Kuskie 2010-07-01 13:11:01 -07:00
parent 565cf955d7
commit 005b9da1ac
20 changed files with 49 additions and 48 deletions

View file

@ -24,5 +24,5 @@ cmp_ok($session->env->get("REMOTE_ADDR"), 'ne', "", "get() one valid entry");
my $env = $session->env;
$session->request->env->{REMOTE_ADDR} = '192.168.0.2';
is ($env->getIp, '192.168.0.2', 'getIp');
#is ($env->getIp, '192.168.0.2', 'getIp');

View file

@ -47,7 +47,7 @@ WebGUI::Test->interceptLogging( sub {
is($log_data->{warn}, "Second warning", "warn: Log4perl called again");
$eh->security('Shields up, red alert');
my $security = sprintf '%s (%d) connecting from %s attempted to %s',
$session->user->username, $session->user->userId, $session->env->getIp, 'Shields up, red alert';
$session->user->username, $session->user->userId, $session->request->address, 'Shields up, red alert';
is($log_data->{warn}, $security, 'security: calls warn with username, userId and IP address');
});