Sha256: 66c16c91dd66c98e5a88f5d144a046f29d8a9f112b99afe490935569b7ba7cd0

Contents?: true

Size: 494 Bytes

Versions: 2

Compression:

Stored size: 494 Bytes

Contents

require 'spec_helper'

describe InfoController do
  let(:context){ double() }
  let(:controller){ InfoController.new(context: context) }

  describe 'index action' do
    before :each do
      Backend.stub(:info){ {} }
    end

    it 'should not fail' do
      context.stub(:haml)
      expect{ controller.index }.not_to raise_error
    end

    it 'should render info template' do
      context.should_receive(:haml).with('info/info'.to_sym, anything)
      controller.index
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
redis_monitor-0.1 spec/controllers/info_controller_spec.rb
redis_monitor-0.0.6 spec/controllers/info_controller_spec.rb