1
0
зеркало из https://github.com/glebtv/telegram-bot.git synced 2026-09-04 10:15:50 +03:00

Easily run UpdatesController's actions without updates

Этот коммит содержится в:
Max Melentiev
2016-03-11 13:03:13 +06:00
родитель e03e39bd53
Коммит 225290b677
8 изменённых файлов: 220 добавлений и 17 удалений

Просмотреть файл

@@ -7,8 +7,8 @@ RSpec.shared_context 'telegram/bot/updates_controller' do
x.extend Telegram::Bot::UpdatesController::Testing
end
end
let(:update) { {payload_type => payload} }
let(:payload_type) { 'some_type' }
let(:update) { build_update(payload_type, payload) }
let(:payload_type) { :some_type }
let(:payload) { double(:payload) }
let(:bot) { Telegram::Bot::ClientStub.new(bot_name) }
let(:bot_name) { 'bot' }

Просмотреть файл

@@ -65,6 +65,10 @@ module Telegram
def session_store=(store)
config.session_store = ActiveSupport::Cache.lookup_store(store)
end
def use_session!
include Session
end
end
end
end