[rspec-users] Autotest file

Bryan Ray bryansray at gmail.com
Thu Feb 28 15:59:58 EST 2008

I'm using rSpec 1.1.3 and ZenTest 3.9.1 and every time I run a test I get
"All Tests Passed" ... perhaps I should just leave it that way? :p

Anyways, I've attempted to construct my own ~/.autotest file and it's
extremely basic, but for some reason whenever I make one test fail (on
purpose) it still kicks off the :green hook rather than the :red one ...

Anybody have any ideas?

# My ~/.autotest file
require 'autotest/redgreen'

module Autotest::Growl
  def self.growl(title, msg, image="", priority=0, sticky="")
    system "growlnotify -n autotest #{sticky} --priority #{priority}
--message '#{msg}' '#{title}'"

  Autotest::add_hook :green do |at|
    growl "Tests Passed!", "All tests passed!"

  Autotest::add_hook :red do |at|
    growl "Tests Failed!", "Tests have failed!"

Bryan Ray

"Programming today is a race between software engineers striving to build
bigger and better idiot-proof programs, and the Universe trying to produce
bigger and better idiots. So far, the Universe is winning."
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/rspec-users/attachments/20080228/12c2f08d/attachment.html 

More information about the rspec-users mailing list