Sha256: 9675d16474bdf07a33808ab9e66d24048c96656cc32a6bc62dd01b22c14dc301

Contents?: true

Size: 616 Bytes

Versions: 10

Compression:

Stored size: 616 Bytes

Contents

require 'spec_helper'

describe Koudoku::SubscriptionsController do
  describe 'when customer is signed in' do
    before do
      @customer = Customer.create(email: 'andrew.culver@gmail.com')
      allow_any_instance_of(ApplicationController).to receive(:current_customer).and_return(@customer)
    end
    it 'works' do
      get :index, use_route: 'koudoku'
    end
  end
  describe 'when customer is not signed in' do
    before do
      allow_any_instance_of(ApplicationController).to receive(:current_customer).and_return(nil)
    end
    it 'works' do
      get :index, use_route: 'koudoku'
    end
  end
end

Version data entries

10 entries across 10 versions & 2 rubygems

Version Path
koudoku-2.0.0 spec/controllers/koudoku/subscriptions_controller.rb
thumbjive-koudoku-1.5.0 spec/controllers/koudoku/subscriptions_controller.rb
koudoku-1.2.4 spec/controllers/koudoku/subscriptions_controller.rb
koudoku-1.2.3 spec/controllers/koudoku/subscriptions_controller.rb
koudoku-1.2.2 spec/controllers/koudoku/subscriptions_controller.rb
koudoku-1.2.1 spec/controllers/koudoku/subscriptions_controller.rb
koudoku-1.2.0 spec/controllers/koudoku/subscriptions_controller.rb
koudoku-1.1.2 spec/controllers/koudoku/subscriptions_controller.rb
koudoku-1.1.1 spec/controllers/koudoku/subscriptions_controller.rb
koudoku-1.1.0 spec/controllers/koudoku/subscriptions_controller.rb