A Slack Bot that pulls Pixiv information and posts the full image(s) into Slack, with iOS shortcuts.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
425 B

9 years ago
  1. require 'spec_helper'
  2. describe RSpec do
  3. let! :command do
  4. Class.new(SlackRubyBot::Commands::Base) do
  5. command 'raise'
  6. def self.call(_client, _data, match)
  7. fail ArgumentError, match[:command]
  8. end
  9. end
  10. end
  11. def app
  12. SlackRubyBot::App.new
  13. end
  14. it 'respond_with_error' do
  15. expect(message: "#{SlackRubyBot.config.user} raise").to respond_with_error(ArgumentError, 'raise')
  16. end
  17. end