class Cinch::Test::MockMessage
Mock class to present Message objects in a more simple fashion
Public Class Methods
new(msg, bot, opts = {})
click to toggle source
Calls superclass method
# File lib/cinch/test.rb, line 50 def initialize(msg, bot, opts = {}) # override the message-parsing stuff super(nil, bot) @message = msg @user = Cinch::User.new(opts.delete(:nick) { 'test' }, bot) if opts.key?(:channel) @channel = Cinch::Channel.new(opts.delete(:channel), bot) @target = @channel else @target = @user end @bot.user_list.find_ensured(nil, @user.nick, nil) end