Sha256: ddfacf921563b57b54c2c37f3c455bb1a0bb6bc8fb7d8816dd310d347995674c
Contents?: true
Size: 554 Bytes
Versions: 8
Compression:
Stored size: 554 Bytes
Contents
describe SlackRubyBot::Commands do let! :command do Class.new(SlackRubyBot::Commands::Base) do command 'nil_text' def self.call(_client, data, _match) send_message client, data.channel, nil end end end let(:app) { SlackRubyBot::App.new } let(:client) { app.send(:client) } let(:message_hook) { SlackRubyBot::Hooks::Message.new } it 'ignores nil messages' do expect(client).to_not receive(:message) message_hook.call(client, Hashie::Mash.new(text: nil, channel: 'channel', user: 'user')) end end
Version data entries
8 entries across 8 versions & 1 rubygems