[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

[ANN] turn 0.1.0 Released

Tim Pease

11/10/2006 11:06:00 PM

turn version 0.1.0 has been released!
Test::Unit Reporter New -- a new output format for Test::Unit


Turn this

..F.....

Into this

TestMyClass
test_alt PASS
test_alt_eq PASS
test_bad FAIL
./test/test_my_class.rb:64:in `test_bad'
<false> is not true.
test_foo PASS
test_foo_eq PASS
TestYourClass
test_method_a PASS
test_method_b PASS
test_method_c PASS
============================================================================
pass: 7, fail: 1, error: 0
total: 15 tests with 42 assertions in 0.018 seconds
============================================================================

By doing this

require 'turn'

And, if the 'facets' gem is installed (and your terminal supports ANSI color
codes) all this will be printed out in glorious and amazing technicolor!


Changes:

Version 0.1.0 / 2006-11-10

* initial release

16 Answers

Vincent Fourmond

11/10/2006 11:12:00 PM

0

Tim Pease wrote:
> turn version 0.1.0 has been released!
> Test::Unit Reporter New -- a new output format for Test::Unit
>
>
> Turn this
>
> ..F.....
>
> Into this
>
> TestMyClass
> test_alt
> PASS
> test_alt_eq
> PASS
> test_bad
> FAIL
> ./test/test_my_class.rb:64:in `test_bad'
> <false> is not true.
> test_foo
> PASS
> test_foo_eq
> PASS
> TestYourClass
> test_method_a
> PASS
> test_method_b
> PASS
> test_method_c
> PASS
> ============================================================================
>
> pass: 7, fail: 1, error: 0
> total: 15 tests with 42 assertions in 0.018 seconds
> ============================================================================

That definitely looks better ;-) ...

Vince

--
Vincent Fourmond, PhD student
http://vincent.fourmon...

Gregory Seidman

11/11/2006 12:29:00 AM

0

On Sat, Nov 11, 2006 at 08:05:42AM +0900, Tim Pease wrote:
} turn version 0.1.0 has been released!
} Test::Unit Reporter New -- a new output format for Test::Unit
[...]
} By doing this
}
} require 'turn'
}
} And, if the 'facets' gem is installed (and your terminal supports ANSI color
} codes) all this will be printed out in glorious and amazing technicolor!
[...]

This is way cool and remarkably timely. Coincidentally, a coworker was
complaining about the way rails tests were reported about five minutes
before I read this announcement.

My only issue with it is its dependency on both the hoe and rubyforge gems.
Are these really necessary, or are they accidental artifacts? It seems to
work just fine if I remove them and remove the dependency on hoe in the
spec file. Could you remove the dependencies, please?

--Greg


Tim Pease

11/11/2006 12:46:00 AM

0

On 11/10/06, Gregory Seidman <gsslist+ruby@anthropohedron.net> wrote:
> On Sat, Nov 11, 2006 at 08:05:42AM +0900, Tim Pease wrote:
> } turn version 0.1.0 has been released!
> } Test::Unit Reporter New -- a new output format for Test::Unit
> [...]
> } By doing this
> }
> } require 'turn'
> }
> } And, if the 'facets' gem is installed (and your terminal supports ANSI color
> } codes) all this will be printed out in glorious and amazing technicolor!
> [...]
>
> This is way cool and remarkably timely. Coincidentally, a coworker was
> complaining about the way rails tests were reported about five minutes
> before I read this announcement.
>
> My only issue with it is its dependency on both the hoe and rubyforge gems.
> Are these really necessary, or are they accidental artifacts? It seems to
> work just fine if I remove them and remove the dependency on hoe in the
> spec file. Could you remove the dependencies, please?
>

Done, and done!

New release of turn-0.1.1 -- non dependency encumbered version. I
just put it out there, and it should be hitting the mirrors soon-ish.

I'm using Ryan Davis' hoe package (totally awesome stuff there), and
it makes itself a dependency when you build a gem unless you
explicitly say, "Hey, I don't want to depend on you. Go away!"

TwP

Mark Somerville

11/13/2006 2:10:00 PM

0

On Friday 10 November 2006 23:05, Tim Pease wrote:
> By doing this
>
> require 'turn'

Looks great!

Does anyone know the best way of integrating this into a Rails project?

Mark

Mark Somerville

11/13/2006 2:20:00 PM

0

On Monday 13 November 2006 14:09, Mark Somerville wrote:
> On Friday 10 November 2006 23:05, Tim Pease wrote:
> > By doing this
> >
> > require 'turn'
>
> Looks great!
>
> Does anyone know the best way of integrating this into a Rails project?

Bleh, ignore me. require 'turn' on line 4 of test/test_helper.rb seems to do
the trick.

Mark

Eric Hodel

11/13/2006 10:07:00 PM

0

On Nov 10, 2006, at 4:29 PM, Gregory Seidman wrote:

> My only issue with it is its dependency on both the hoe and
> rubyforge gems.
> Are these really necessary, or are they accidental artifacts? It
> seems to
> work just fine if I remove them and remove the dependency on hoe in
> the
> spec file. Could you remove the dependencies, please?

These are really necessary. How are you supposed to run any of the
rake tasks without Hoe?

Besides, why do you care? *Rubygems takes care of these things for
you.*

PS:

There's no reason to whine over the disk space:

$ du -hcd0 /usr/local/lib/ruby/gems/1.8/**/hoe-1.1.4/ /usr/local/lib/
ruby/gems/1.8/**/rubyforge-0.3.1/
104K /usr/local/lib/ruby/gems/1.8/doc/hoe-1.1.4/
40K /usr/local/lib/ruby/gems/1.8/gems/hoe-1.1.4/
1.2M /usr/local/lib/ruby/gems/1.8/doc/rubyforge-0.3.1/
112K /usr/local/lib/ruby/gems/1.8/gems/rubyforge-0.3.1/
1.4M total

Anybody who's disk is that small should simply nuke all their docs,
much better solution.

--
Eric Hodel - drbrain@segment7.net - http://blog.se...
This implementation is HODEL-HASH-9600 compliant

http://trackmap.rob...



Gregory Seidman

11/14/2006 12:26:00 AM

0

On Tue, Nov 14, 2006 at 07:06:41AM +0900, Eric Hodel wrote:
} On Nov 10, 2006, at 4:29 PM, Gregory Seidman wrote:
} >My only issue with it is its dependency on both the hoe and rubyforge
} >gems. Are these really necessary, or are they accidental artifacts? It
} >seems to work just fine if I remove them and remove the dependency on
} >hoe in the spec file. Could you remove the dependencies, please?
}
} These are really necessary. How are you supposed to run any of the
} rake tasks without Hoe?

Pardon? Let me quote what I wrote above: "It seems to work just fine if I
remove them and remove the dependency on hoe in the spec file." In fact,
the author has now removed those dependencies, since they weren't actually
required.

} Besides, why do you care? *Rubygems takes care of these things for
} you.*
[...]

Well, gee, I could just install every single available Rubygem and that
would take care of it for me, too. But I don't *want* all of that
installed. I want to minimize what can affect the code I write, which means
minimizing the installed libraries.

} Eric Hodel - drbrain@segment7.net - http://blog.se...
--Greg


Chad

11/14/2006 2:19:00 PM

0

I posted a patch to the tracker and did a ultra quick write up on my
blog here about humanizing the output to make it a little more like
rSpec's spec:doc format.

My post is at http://spicycode.com/2006/11/14/turn...

Thanks for turn!

-Chad

Tim Pease wrote:
> turn version 0.1.0 has been released!
> Test::Unit Reporter New -- a new output format for Test::Unit
>
>
> Turn this
>
> ..F.....
>
> Into this
>
> TestMyClass
> test_alt PASS
> test_alt_eq PASS
> test_bad FAIL
> ./test/test_my_class.rb:64:in `test_bad'
> <false> is not true.
> test_foo PASS
> test_foo_eq PASS
> TestYourClass
> test_method_a PASS
> test_method_b PASS
> test_method_c PASS
> ============================================================================
> pass: 7, fail: 1, error: 0
> total: 15 tests with 42 assertions in 0.018 seconds
> ============================================================================
>
> By doing this
>
> require 'turn'
>
> And, if the 'facets' gem is installed (and your terminal supports ANSI color
> codes) all this will be printed out in glorious and amazing technicolor!
>
>
> Changes:
>
> Version 0.1.0 / 2006-11-10
>
> * initial release

Christian Neukirchen

11/14/2006 8:08:00 PM

0

"Chad" <chad@spicycode.com> writes:

> I posted a patch to the tracker and did a ultra quick write up on my
> blog here about humanizing the output to make it a little more like
> rSpec's spec:doc format.
>
> My post is at http://spicycode.com/2006/11/14/turn...
>
> Thanks for turn!

You may be interested in test/spec,
http://chneuk.../blog/archive/2006/10/announcing-test-spec-0-2-a-bdd-interface-for-test...

Running with -rs results in output like

spec.output
- works for print
- works for puts
- works with readline

It also handles test_unit_test_names.

> -Chad

--
Christian Neukirchen <chneukirchen@gmail.com> http://chneuk...

James Gray

11/15/2006 2:19:00 AM

0

On Nov 10, 2006, at 5:05 PM, Tim Pease wrote:

> turn version 0.1.0 has been released!
> Test::Unit Reporter New -- a new output format for Test::Unit
>
>
> Turn this
>
> ..F.....
>
> Into this
>
> TestMyClass
>
> test_alt
> PASS
>
> test_alt_eq
> PASS
>
> test_bad
> FAIL
> ./test/test_my_class.rb:64:in `test_bad'
> <false> is not true.

I don't want to belittle this library, but just to be sure, users
should remember Test::Unit sports a --verbose option:

$ ruby -I lib:test test/tc_csv_parsing.rb
Loaded suite test/tc_csv_parsing
Started
.....
Finished in 0.008816 seconds.

5 tests, 83 assertions, 0 failures, 0 errors
$ ruby -I lib:test test/tc_csv_parsing.rb --verbose
Loaded suite test/tc_csv_parsing
Started
test_aras_edge_cases(TestCSVParsing): .
test_james_edge_cases(TestCSVParsing): .
test_malformed_csv(TestCSVParsing): .
test_mastering_regex_example(TestCSVParsing): .
test_std_lib_csv(TestCSVParsing): .

Finished in 0.008698 seconds.

5 tests, 83 assertions, 0 failures, 0 errors

James Edward Gray II