# Turn 0.4.0

**URL:** <https://www.ruby-forum.com/t/turn-0-4-0/154319>\
**Category:** Ruby\
**Created:** [November 27, 2008, 5:06pm UTC](https://www.ruby-forum.com/t/turn-0-4-0/154319 "2008-11-27T17:06:52Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![unknown](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/u/4bbf92/32.png) [@unknown](https://www.ruby-forum.com/u/unknown)\
**Post date:** [November 27, 2008, 5:06pm UTC](https://www.ruby-forum.com/t/turn-0-4-0/154319/1 "2008-11-27T17:06:52Z")

</div>

turn version 0.4.0  
by Tim P.  
[http://codeforpeople.rubyforge.org/turn](http://codeforpeople.rubyforge.org/turn)

== DESCRIPTION:

TURN is a new way to view Test::Unit results. With longer running tests,  
it  
can be very frustrating to see a failure (…F…) and then have to  
wait till  
all the tests finish before you can see what the exact failure was. TURN  
displays each test on a separate line with failures being displayed  
immediately instead of at the end of the tests.

== WHAT’S NEW:

While Turn still provides the exact same functionality for running  
tests via ruby or testrb as previous versions. The turn commandline  
utility has been completely rewritten with expanded capabilites.

The turn command now features three run modes:

- Solo runner for running each test file in a separate process.
- Cross runner for running test file pairs in separate processes.
- Normal runner, which of course runs all test in a single process.

It also support three report modes:

- Progress reporter which uses a progress bar.
- Minimal reporter which provides traditional “dot” progress.
- Outline reporter populaized by turn.

The is also a special Marshal Mode which dumps test results as YAML.  
And the underlying API makes it easy create new reporters.

To get a quick rundown on how to use the new commandline:

turn --help

Enjoy!

== CHANGES

- add solo and cross runners
- move Colorize into separate file
- use ::ANSICode instead of ::Console::ANSICode

---

<div class="post-metadata">

**Author:** ![unknown](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/u/4bbf92/32.png) [@unknown](https://www.ruby-forum.com/u/unknown)\
**Post date:** [December 1, 2008, 4:28pm UTC](https://www.ruby-forum.com/t/turn-0-4-0/154319/2 "2008-12-01T16:28:30Z")

</div>

On Nov 27, 9:01 am, removed\_email\_address@domain.invalid wrote:

> immediately instead of at the end of the tests.
> 
> - Cross runner for running test file pairs in separate processes.
> 
> To get a quick rundown on how to use the new commandline:
> 
> turn–help
> 
> Enjoy!
> 
> == CHANGES
> 
> - add solo and cross runners
> - move Colorize into separate file
> - use ::ANSICode instead of ::Console::ANSICode

Thanks Tim. I’m working with Kouhei to figure how to make this the  
default test runner for Test::Unit 2.x, since the runners have been  
split out from the main code. I’m pretty sure they’re pluggable, and  
should be configurable via a YAML file. Once I figure that out, I’ll  
post it here.

Regards,

Dan

---

<div class="post-metadata">

**Author:** ![unknown](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/u/4bbf92/32.png) [@unknown](https://www.ruby-forum.com/u/unknown)\
**Post date:** [December 8, 2008, 2:42pm UTC](https://www.ruby-forum.com/t/turn-0-4-0/154319/3 "2008-12-08T14:42:21Z")

</div>

On Nov 27, 9:01 am, removed\_email\_address@domain.invalid wrote:

> immediately instead of at the end of the tests.

Hm, when I tried to use it with Test::Unit 2.x, I got this:

daniel-bergers-computer:~/Documents/workspace/file-find/test djberge$  
rake test  
(in /Users/djberge/Documents/workspace/file-find)  
Loaded suite /usr/local/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake/  
rake\_test\_loader  
/usr/local/lib/ruby/gems/1.8/gems/turn-0.4.0/lib/turn.rb:17: warning:  
instance variable @io not initialized  
/usr/local/lib/ruby/gems/1.8/gems/turn-0.4.0/lib/turn.rb:17:in  
`attach_to_mediator': undefined method`sync=’ for nil:NilClass  
(NoMethodError)  
from /usr/local/lib/ruby/gems/1.8/gems/test-unit-2.0.1/lib/  
test/unit/ui/console/testrunner.rb:53:in `start' from /usr/local/lib/ruby/gems/1.8/gems/test-unit-2.0.1/lib/ test/unit/ui/testrunnerutilities.rb:24:in`run’  
from /usr/local/lib/ruby/gems/1.8/gems/test-unit-2.0.1/lib/  
test/unit/autorunner.rb:234:in `run' from /usr/local/lib/ruby/gems/1.8/gems/test-unit-2.0.1/lib/ test/unit/autorunner.rb:29:in`run’  
from /usr/local/lib/ruby/gems/1.8/gems/test-unit-2.0.1/lib/  
test/unit.rb:278  
from /usr/local/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake/  
rake\_test\_loader.rb:5  
rake aborted!  
Command failed with status (1): [/usr/local/bin/ruby -w -Ilib:lib "/  
usr/loc…]

Any suggestions?

Thanks,

Dan

PS - Also, it looks like Bones should be marked as a dependency for  
Turn.

---

<div class="post-metadata">

**Author:** ![unknown](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/u/4bbf92/32.png) [@unknown](https://www.ruby-forum.com/u/unknown)\
**Post date:** [December 8, 2008, 5:59pm UTC](https://www.ruby-forum.com/t/turn-0-4-0/154319/4 "2008-12-08T17:59:03Z")

</div>

On Dec 8, 2008, at 6:34 AM, Daniel B. wrote:

> > tests, it
> 
> ```
> from /usr/local/lib/ruby/gems/1.8/gems/test-unit-2.0.1/lib/
> 
> ```
> 
> rake\_test\_loader.rb:5  
> rake aborted!  
> Command failed with status (1): [/usr/local/bin/ruby -w -Ilib:lib "/  
> usr/loc…]
> 
> Any suggestions?

I’ll look into it.

Bones is actually a development dependency, but there should be  
something in the readme about setting up a development environment and  
the required Mr Bones gem.

Thanks, Daniel. You should come up to the ruby users group again. We  
miss you; but I understand it’s a bit of a drive.

Blessings,  
TwP
