Hi all,
I was just thinking that since my tests are nicely orthogonal and yet
there's very little cpu utilization during testing, that I could
probably get them done about 20x faster if they were parallelized.
Has anyone looked at doing this with TAPx::Harness or otherwise? Is
there a big underlying assumption that I'm missing which would prevent
tests from being run concurrently in different processes (or on
different machines?)
Just briefly glancing at the code in svn, it looks like overriding
aggregate_tests would do the trick, except all I would really need to
rewrite would be the inner foreach loop. What troubles me is the few
lexicals that would then have to be passed in, as those appear to be
mostly for formatting purposes. Perhaps pre-figuring the formatting
("$name$periods") and then calling an overridable tests_loop method
with a list of array refs and the $aggregate object would better lend
itself to subclassing?
$self->test_loop($aggregate, [[$label, $test] ,...]);
There's also the bail-out issue, but maybe die()ing with an error object
(or something) rather than "exit 1" would allow the parent to see that
one child is waving the white flag and call off the rest of them asap.
Thanks,
Eric
--
software: a hypothetical exercise which happens to compile.
---------------------------------------------------
http://scratchcomputing.com
---------------------------------------------------