Sha256: b056cf46b0059860619392442b02d971408274c722d9f095e7b3527a6dadccb3

Contents?: true

Size: 396 Bytes

Versions: 2

Compression:

Stored size: 396 Bytes

Contents

require 'rails_helper'

module Popolo
  RSpec.describe PeopleController, type: :controller do
    routes { Engine.routes }

    before :each do
      @person = FactoryGirl.create(:person)
    end

    describe 'GET show' do
      it 'assigns the requested person as @person' do
        get :show, {id: @person.to_param}
        expect(assigns(:person)).to eq(@person)
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
popolo-0.1.1 spec/controllers/popolo/people_controller_spec.rb
popolo-0.1.0 spec/controllers/popolo/people_controller_spec.rb