Skip to content

Commit

Permalink
adds passing test for #new in student profiles controller
Browse files Browse the repository at this point in the history
  • Loading branch information
ric9176 committed Apr 7, 2016
1 parent c6f484c commit e79214f
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions spec/controllers/student_profiles_controller_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,19 @@

RSpec.describe StudentProfilesController, type: :controller do
describe 'GET new' do
xit 'assigns @student_profile' do
it 'assigns @student_profile' do
student_profile = StudentProfile.new
get :new
expect(assigns(:student_profile)).to eq([student_profile])
expect(assigns(:student_profile)).to be_a_new(StudentProfile)
end
it "renders the new template" do
get :new
expect(response).to render_template("new")
end
end
end


# student_profile = StudentProfile.new
# get :new
# expect(assigns(:student_profiles)).to eq([student_profile])

0 comments on commit e79214f

Please sign in to comment.