[Wtr-general] How to make sure that script run in line squence rather than alphabetical sequence when using load
Jason He
jhe at resilience.com
Wed Mar 7 02:46:42 EST 2007
Dear all,
It seems that the code executing sequence is accorrding to the alphabetical rather than according to the line number in the script, when include test cases using load (or require) method. For example, the test cases sequence in scritp "test.rb" as follow,
load 'rt/rt_r_login.rb'
load 'rt/rt_w_login.rb'
load 'rt/rt_r_system_admin_nameserver.rb'
load 'rt/rt_w_system_admin_nameserver.rb'
load 'rt/rt_r_system_admin_admin_password.rb'
load 'rt/rt_w_system_admin_admin_password.rb'
load 'rt/rt_r_system_admin_admin_mail.rb'
load 'rt/rt_w_system_admin_admin_mail.rb'
In fact that the executing sequence as follow,
./rt/rt_r_login.rb
./rt/rt_r_system_admin_admin_mail.rb
./rt/rt_r_system_admin_admin_password.rb
./rt/rt_r_system_admin_nameserver.rb
./rt/rt_w_login.rb
./rt/rt_w_system_admin_admin_mail.rb
./rt/rt_w_system_admin_admin_password.rb
./rt/rt_w_system_admin_nameserver.rb
Now, I want to use the line sequence in script "test.rb" rather alphabetical sequence, is there a way to achieve it?
Regards,
Jason
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/wtr-general/attachments/20070307/3257ba0f/attachment-0001.html
More information about the Wtr-general
mailing list