Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
comp.lang.ruby
Waiting for exeution to end.
Max Russell
1/8/2008 4:09:00 PM
I have a snippet of code like this:
class TestSuite < Watir::TestCase
File.open(ARGV[0]||'testlist.txt').each_line do |entry|
if entry[0] == "#"
pass
else
code = lambda{load "#{entry.strip}.rb" }
self.send(:define_method, entry.strip, code)#{load
"#{entry.strip}.rb" }#puts "#{entry.strip}"
#self.send(:public, entry.strip.to_sym )
end
end
end
if $0 == __FILE__
require 'test/unit/ui/console/testrunner'
Test::Unit::UI::Console::TestRunner.run(TestSuite)
end
which basically is a harness to run a load of tests using WATIR. I've
written some reporting tools, using a class called Grapher. What I'd
like to happen, is the test suite runs, then the grapher performs its
task. However, if I place the call to grapher after the line
Test::Unit::UI::Console::TestRunner.run(TestSuite), it executes before
the tests have completed execution.
I'm looking for an elegant solution to this - should I spawn a process
or something?
--
Posted via
http://www.ruby-...
.
1 Answer
Max Russell
1/9/2008 3:36:00 PM
0
is there a way to use yield here around the execute line?
--
Posted via
http://www.ruby-...
.
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
Waiting for exeution to end.
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password