Sha256: aab8f1cd0bf7335577e2a6c8864a2c64a0bfb90263c0b638308695cdf349be4d

Contents?: true

Size: 639 Bytes

Versions: 10

Compression:

Stored size: 639 Bytes

Contents

require 'spec_helper'

describe 'Student Enrollment Status' do

  before(:all) { set_resource 'student' }
  before { as :admin }

  let(:student) { create(:student) }
  let!(:enrollment_status) { create(:enrollment_status, name: 'Enrolled', code: 'enrolled') }

  it 'create and show', js: true do
    visit gaku.edit_student_path(student)
    select enrollment_status.name, from: 'student_enrollment_status_code'
    click submit

    flash_updated?
    within('#student_enrollment_status_code') { has_content? enrollment_status.name }
    student.reload
    expect(student.enrollment_status_code).to eq enrollment_status.code
  end

end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
gaku-0.2.4 frontend/spec/features/students/enrollment_status_spec.rb
gaku-0.2.3 frontend/spec/features/students/enrollment_status_spec.rb
gaku-0.2.2 frontend/spec/features/students/enrollment_status_spec.rb
gaku-0.2.1 frontend/spec/features/students/enrollment_status_spec.rb
gaku-0.2.0 frontend/spec/features/students/enrollment_status_spec.rb
gaku-0.1.1 frontend/spec/features/students/enrollment_status_spec.rb
gaku-0.1.0 frontend/spec/features/students/enrollment_status_spec.rb
gaku-0.0.3 core/spec/requests/students/enrollment_status_spec.rb
gaku-0.0.2 core/spec/requests/students/enrollment_status_spec.rb
gaku-0.0.1 core/spec/requests/students/enrollment_status_spec.rb