Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • Will reusing the same Firefox process cause a problem?

    Your arguments in favor of reusing the process are very similar to my arguments in favor of running tests in a single process with Test::Aggregate. Even though it's worked very well, a few people raked me over the coals for this decision. I wonder if they'll give you the same level of grief :)

    • A web browser is designed to keep things strictly separated. Perl is, at best, a half-blind chaperonage in a French farce.

      Test::Aggregate is the mod_perl of the testing world. If you take a bunch of things which were all designed to run in their own process once and then terminate and try to smash them together they're going to step all over each other and themselves. It requires careful recrafting, and restricting, of the formerly independent tests for them to all run together. Even then you can't be sure a failure wasn't due to some sort of bizarre interaction. For laughs I tried to run MakeMaker's test suite aggregated and it didn't even make it out of the gate because of an __END__ block in one of the tests. Gravatar::URL worked, but that's a very simple module with very simple tests.

      In a browser about the worst that can happen is you've got some left over cookies set, and I think there's a Selenium widget to clear them. Javascript will have no memory between runs by design.

      So while the benefits may be the same, speed, reusing a browser process is a natural extension of how a browser works and gets used. Whereas Test::Aggregate is granted no such slack and test authors have to constantly be on guard. This is not meant as an indictment of TA, but an acknowledgment that one is an engineering feat against stacked odds while the other is just using a thing as designed.