ZenTest: November 2006 Archives

ZenTest 3.4.2 Released

| | Comments (1)

ZenTest version 3.4.2 has been released! Between this and today's Hoe release with test_deps should fix all issues with autotest and rake test disagreeing.

ZenTest provides 4 different tools and 1 library: zentest, unit_diff, autotest, multiruby, and Test::Rails.

ZenTest scans your target and unit-test code and writes your missing code based on simple naming rules, enabling XP at a much quicker pace. ZenTest only works with Ruby and Test::Unit.

unit_diff is a command-line filter to diff expected results from actual results and allow you to quickly see exactly what is wrong.

autotest is a continous testing facility meant to be used during development. As soon as you save a file, autotest will run the corresponding dependent tests.

multiruby runs anything you want on multiple versions of ruby. Great for compatibility checking!

Test::Rails helps you build industrial-strength Rails code.

Changes:

3.4.2 / 2006-11-09

  • 2 minor enhancements:
    • Add TextHelper for pluralize.
    • Add deny_nil to Test::Rails.
  • 7 bug fixes:
    • Fixed testhelp's Flash. It's is a module. Oops...
    • Don't run utilauditassertassigned if tests didn't pass, results will be bogus.
    • Fixed AssertionsTest names to match what autotest expects.
    • Fixed bug where denyincludes failed for Symbol keys.
    • Switched autotest to use require instead of load... Why??? I don't know!!
    • Fixed a minor but annoying whitespace difference in unitdiff.
    • Switched argument order of assertincludes and denyincludes to match Test::Unit convention.

rake passes but autotest fails?

| | Comments (2)

Fix Your Dependencies!!!

Yipstar finally provided me a producible test case for the situation a number of people have told me about but couldn't boil down. The whole thing is so dead simple. That is why I think I missed it this whole time:

rake:

ruby -e "require 'test_a'; require 'test_b'; ..."

autotest:

ruby -e "...; require 'test_b'; require 'test_a'"

If your tests break by simply changing the order in which they load then you have dependency issues! Every single test file you have should be able to run independently of all others (which is a damn powerful tool to have in combination with -n "/regex/").

(As an aside, I worked with yipstar and we got his tests all patched up and autotest still had a problem because it uses load, not require... no clue... Eric and I are going to look into that tomorrow)

Some of you will want me to "fix autotest"... BAH! Autotest isn't broken! Your tests are! I will add another task to Hoe that will help point out all test files that don't pass independently so you can go and patch up your tests.

% rake test_deps
Dependency Issues: test/test_a.rb
Dependency Issues: test/test_c.rb
...

We should have a release later today for both ZenTest and Hoe with new testy goodness.

About this Archive

This page is a archive of entries in the ZenTest category from November 2006.

ZenTest: October 2006 is the previous archive.

ZenTest: December 2006 is the next archive.

Find recent content on the main index or look in the archives to find all content.

Pages

Powered by Movable Type 4.1