Sha256: bcd7c8bb2a0c3aacaab0d477c09da34b3c45f65b4fa67682c8a774b53f2d4231
Contents?: true
Size: 862 Bytes
Versions: 9
Compression:
Stored size: 862 Bytes
Contents
require File.dirname(__FILE__) + '/test_helper' require 'cerberus/publisher/jabber' require 'cerberus/manager' require 'mock/xmpp4r' require 'mock/manager' class JabberPublisherTest < Test::Unit::TestCase def test_publisher options = Cerberus::Config.new(nil, :publisher => {:jabber => {:jid=>'from.cerberus@gmail.com', :recipients => ' jit1@google.com, another@google.com '}}, :application_name => 'MegaApp') build = DummyManager.new('last message', 'this is output', 1232, 'anatol') Cerberus::Publisher::Jabber.publish(build_status(false), build, options) messages = Jabber::Client.messages assert messages.size > 2 assert_equal 'google.com', messages[0].to.domain assert_equal 'jit1', messages[0].to.node assert_equal '[MegaApp] Build still broken (1232)', messages[0].subject assert !messages[0].body.nil? end end
Version data entries
9 entries across 9 versions & 2 rubygems