I don't like the duplication, either. But I'm having a hard time conjuring up a regex that is right for test-unit, but not wrong for cucumber. The example you gave, for example, would miss a test unit run with a single test. An edge-case, for sure, but still...

Ultimately, it looks like that gsub's purpose is to protect against a false regex miss due to scrambled output in test-unit and rspec. So, I've tried moving the filter into the `line_is_result?` method, since I think that's where that responsibility belongs. This solves the problem, removes the duplication, and all the tests still pass.

Pushing some new commits presently.