fnando/test_notifier — Issue #13: autotest: warning about missing osd_cat when default is set as knotify
Author: zesty
Created: 2011-11-03 13:33:42+00:00
State: open

Perhaps I configured something wrong, but it appears that "test_notifier/runner/autotest" doesn't know about TestNotifier.default_notifier. When using autotest I get an error for osd_cat, which I think it shouldn't be trying to find. No such warning comes when just using rake on the commandline (which uses instead: 'test_notifier/runner/rspec'). Output of autotest and files in play follow:

------------------OUTPUT----------------------------

something
does something

Finished in 0.16497 seconds
1 example, 0 failures
which: no osd_cat in (/home/leary/.rvm/bin:/home/leary/.rvm/gems/ruby-1.9.2-p290/bin:/home/leary/.rvm/gems/ruby-1.9.2-p290@global/bin:/home/leary/.rvm/rubies/ruby-1.9.2-p290/bin:/home/leary/./bin:/usr/local/bin:/usr/bin:/bin:/opt/openoffice.org3/program/:/opt/kde/bin:/usr/X11R6/bin:/usr/games:/usr/local/java/bin:/home/leary/bin:.)

# Waiting since 2011-11-03 06:24:07

-----------------------FILES---------------------------------

% cat .autotest
require 'autotest/timestamp'
require 'autotest/restart'
require "test_notifier/runner/autotest"
TestNotifier.default_notifier = :knotify

Autotest.add_hook :initialize do |autotest|
%w{ .git }.each do |exception| # .hg? vendor tmp log doc
autotest.add_exception(exception)
end
end

--------------------------------------------

% cat Rakefile
# encoding: utf-8

require 'rspec/core/rake_task'

RSpec::Core::RakeTask.new(:spec) do |spec|
spec.pattern = FileList['spec/**/*_spec.rb']
end

task :default => :spec

require 'bundler'
begin
Bundler.setup(:default, :development)
rescue Bundler::BundlerError => e
$stderr.puts e.message
$stderr.puts "Run `bundle install` to install missing gems"
exit e.status_code
end

--------------------------------------------

% cat spec/spec_helper.rb
require 'test_notifier/runner/rspec'
TestNotifier.default_notifier = :knotify
require 'simplecov'
SimpleCov.start

--------------------------------------------

% cat spec/thing_spec.rb
require 'rspec'

describe "something" do
it "does something" do
# pass
end
end