Re: [Http-webtest-general] on_response question
Brought to you by:
m_ilya,
richardanderson
From: Ilya M. <il...@ip...> - 2003-04-02 12:56:59
|
>>>>> "RB" == Remo Behn <fo...@we...> writes: RB> On Tue, 01 Apr 2003 14:36:05 +0400 RB> Ilya Martynov <il...@ip...> wrote: >> >>>>> "RB" == Remo Behn <fo...@we...> writes: RB> [...] RB> sorry, don't work, i am stupid ??? RB> i'm not understand the concept ;( RB> i have attach my *.wt and an Data::Dumper output RB> cu RB> -- RB> RayMan <fo...@we...> RB> ignore_case = no RB> mail = no RB> mail_addresses = ( foobar@localhost ) RB> mail_server = localhost RB> method = POST RB> [ ... cut other tests ... ] RB> test_name = 'login with as cyrus (EN)' RB> url = http://localhost/app/login.pl RB> params = ( RB> uid => cyrus RB> passwd => cyrus RB> doit => login RB> lang => EN RB> ) RB> #-- get sessionID RB> on_response = { RB> my $webtest = shift; RB> ($SID) = $webtest->current_response->header('refresh'); RB> $SID =~ s/.*sessionID=([\d\w]+).*/$1/; RB> []; RB> } RB> end_test RB> test_name = 'logout cyrus (EN)' RB> url = http://localhost/app/menu.pl?sessionID=$SID You'll have to take put this parameters in double quotes or it will not expand value of $SID I.e. url = "http://localhost/app/menu.pl?sessionID=$SID" RB> params = ( RB> tab => logout RB> lang => EN RB> sessionID => $SID Same problem here. Should be sessionID => "$SID" RB> ) RB> end_test -- Ilya Martynov, il...@ip... CTO IPonWEB (UK) Ltd Quality Perl Programming and Unix Support UK managed @ offshore prices - http://www.iponweb.net Personal website - http://martynov.org |