Sha256: 823f6c644dbde55c6fc37cf81b6ae6bffcedf20355aa576ffa7ffa5728262ea2
Contents?: true
Size: 897 Bytes
Versions: 1
Compression:
Stored size: 897 Bytes
Contents
require File.dirname(__FILE__) + '/test_helper.rb' class TestNotification < Test::Unit::TestCase def setup @title = "title" @msg = "message" @image = "image" end def test_notify_when_os_is_windows notifier = Autotestforphp::Notification::Windows notifier.expects(:notify).with(@title, @msg, @image) verify_to("mswin") end def test_notify_when_os_is_linux notifier = Autotestforphp::Notification::Linux notifier.expects(:notify).with(@title, @msg, @image) verify_to("linux") end def test_notify_when_os_is_mac notifier = Autotestforphp::Notification::Mac notifier.expects(:notify).with(@title, @msg, @image) verify_to("darwin") end private def verify_to(so) Autotestforphp::Notification.const_set :RUBY_PLATFORM, so Autotestforphp::Notification.notify(@title, @msg, @image) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
autotestforphp-0.0.3 | test/test_notification.rb |