[Wtr-general] How to make sure that script run in line squencerather than alphabetical sequence when using load
Jason He
Jason.He at resilience.com
Thu Mar 8 04:22:18 EST 2007
Yes, give the class name with suffix “Sequence” can make sure the code executing sequence according to line number in the script.
However, it seems that code in the other script won’t execute when “load” method is embraced in the class/function block.
---------------------------------------------------------------------------
require 'watir/testcase'
class TC2_Sequential < Watir::TestCase
def test_b;
load 'rt/rt_r_login.rb';
print 'E';
end
def test_a;
load 'rt/rt_w_login.rb'
print 'F';
end
def test_d;
load 'rt/rt_r_system_admin_nameserver.rb'
print 'G';
end
def test_c;
load 'rt/rt_w_system_admin_nameserver.rb'
print 'H';
end
end
---------------------------------------------------------------------------
The output as follow,
---------------------------------------------------------------------------
C:\watir1145>test.rb
Loaded suite C:/watir1145/test
Started
E.F.G.H.
Finished in 0.0 seconds.
4 tests, 0 assertions, 0 failures, 0 errors
---------------------------------------------------------------------------
Is there anything I missed?
Regards,
Jason
________________________________
From: wtr-general-bounces at rubyforge.org [mailto:wtr-general-bounces at rubyforge.org] On Behalf Of ?eljko Filipin
Sent: 2007年3月7日 19:19
To: wtr-general at rubyforge.org
Subject: Re: [Wtr-general] How to make sure that script run in line squencerather than alphabetical sequence when using load
Maybe this will help.
http://wiki.openqa.org/display/WTR/Test-Unit+Patch
--
Zeljko Filipin
zeljkofilipin.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/wtr-general/attachments/20070308/610aa01d/attachment.html
More information about the Wtr-general
mailing list