Sha256: ecbf6156ae9eaa15cb13fd128fdfac6aae0d9745ecaa057982e416db93c5cda8
Contents?: true
Size: 601 Bytes
Versions: 2
Compression:
Stored size: 601 Bytes
Contents
require 'spec_helper' describe SlackRubyBot::Commands do let! :command do Class.new(SlackRubyBot::Commands::Base) do command 'send_message_spec' do |client, data, match| client.say(channel: data.channel, text: match['expression']) end end end def app SlackRubyBot::App.new end let(:client) { app.send(:client) } it 'sends a message' do expect(client).to receive(:message).with(channel: 'channel', text: 'message') app.send(:message, client, text: "#{SlackRubyBot.config.user} send_message_spec message", channel: 'channel', user: 'user') end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
slack-ruby-bot-0.6.1 | spec/slack-ruby-bot/commands/send_message_spec.rb |
slack-ruby-bot-0.6.0 | spec/slack-ruby-bot/commands/send_message_spec.rb |