Test::Unit 0.1.8 reporting problem

I recently upgraded my testunit package from 0.1.6 to 0.1.8. Besides renaming set_up to setup and tear_down to teardown (I new that I would have to do it) I found another problem, or nuisance, rather:

When outputting a single ‘.’ to stdout on a test completion (before it was to stderr, I guess), stdout is not flushed. So you actually see results only after all tests are done. If a test takes some time to finish, you do not see any output for a while, and then a burst of dots are dumped on you.

I fixed it on my system in “test/unit/ui/console/testrunner.rb” by adding @io.flush after @io.write in “output_single” method, however it would be nice to have it fixed it the RAA distribution of testunit.

Regards,
Gennady.

You could try calling ‘STDOUT.sync’ in your setup() method?

Regards,

Brian.

···

On Wed, Jun 25, 2003 at 02:21:49AM +0900, Gennady wrote:

I recently upgraded my testunit package from 0.1.6 to 0.1.8. Besides renaming set_up to setup and tear_down to teardown (I new that I would have to do it) I found another problem, or nuisance, rather:

When outputting a single ‘.’ to stdout on a test completion (before it was to stderr, I guess), stdout is not flushed. So you actually see results only after all tests are done. If a test takes some time to finish, you do not see any output for a while, and then a burst of dots are dumped on you.

I fixed it on my system in “test/unit/ui/console/testrunner.rb” by adding @io.flush after @io.write in “output_single” method, however it would be nice to have it fixed it the RAA distribution of testunit.

I recently upgraded my testunit package from 0.1.6 to 0.1.8. Besides
renaming set_up to setup and tear_down to teardown (I new that I
would have to do it) I found another problem, or nuisance, rather:

When outputting a single ‘.’ to stdout on a test completion (before
it was to stderr, I guess), stdout is not flushed. So you actually
see results only after all tests are done. If a test takes some time
to finish, you do not see any output for a while, and then a burst
of dots are dumped on you.

I fixed it on my system in “test/unit/ui/console/testrunner.rb” by
adding @io.flush after @io.write in “output_single” method, however
it would be nice to have it fixed it the RAA distribution of testunit.

Agreed, and I’ve added it to the TODO list.

BTW, just to let everyone know, I haven’t dropped off the face of the
earth. I have, however, been quite busy, and unfortunately I haven’t
been able to code much Ruby lately.

But, thankfully, that’s changed recently. I’m now working on a project
that’s going to use Ruby exclusively (since I get to pick ;-), and
expect to be devoting more time to Ruby things in general. So I may
actually begin to cut down on that TODO list again.

Stay tuned…

Nathaniel

<:((><

···

Gennady [mailto:gfb@tonesoft.com] wrote:

EQUIP VI