Sha256: 9fa60f88bdf6d5ede33a2242fea9c730bf96ac19efdaf9d6f5a8230159596a08

Contents?: true

Size: 530 Bytes

Versions: 2

Compression:

Stored size: 530 Bytes

Contents

require 'spec_helper'

module Adhearsion::Asterisk
  describe 'plugin loading' do
    before(:all) { Adhearsion::Plugin.init_plugins }

    let(:mock_call) { stub_everything 'Call' }

    it 'should monkeypatch Adhearsion::CallController' do
      cc = Adhearsion::CallController.new(mock_call)
      cc.expects(:play_time).returns true
      cc.play
    end

    it 'should extend Adhearsion::CallController with Asterisk methods' do
      Adhearsion::CallController.new(mock_call).should respond_to :play_time
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
adhearsion-asterisk-0.2.0 spec/adhearsion/asterisk/plugin_spec.rb
adhearsion-asterisk-0.1.3 spec/adhearsion/asterisk/plugin_spec.rb