Sha256: abbc4a5e0dbcbc9ba3883c809dea47cc94f6345d25d3f476d45ac384e8979da5

Contents?: true

Size: 887 Bytes

Versions: 7

Compression:

Stored size: 887 Bytes

Contents

require File.expand_path('../../../spec_helper', __FILE__)

module NcsNavigator::Mdes
  describe DispositionCode do
    let(:code) { DispositionCode.new({}) }

    describe '#success?' do
      describe 'if #final_category starts with "Complete"' do
        before do
          code.final_category = 'Complete Interview'
        end

        it 'returns true' do
          code.should be_success
        end
      end

      describe 'if #final_category does not start with "Complete"' do
        before do
          code.final_category = 'Eligible Non-Interview'
        end

        it 'returns false' do
          code.should_not be_success
        end
      end

      describe 'if #final_category is nil' do
        before do
          code.final_category = nil
        end

        it 'returns false' do
          code.should_not be_success
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
ncs_mdes-0.13.0 spec/ncs_navigator/mdes/disposition_code_spec.rb
ncs_mdes-0.12.0 spec/ncs_navigator/mdes/disposition_code_spec.rb
ncs_mdes-0.11.0 spec/ncs_navigator/mdes/disposition_code_spec.rb
ncs_mdes-0.10.0 spec/ncs_navigator/mdes/disposition_code_spec.rb
ncs_mdes-0.9.0 spec/ncs_navigator/mdes/disposition_code_spec.rb
ncs_mdes-0.8.1 spec/ncs_navigator/mdes/disposition_code_spec.rb
ncs_mdes-0.8.0 spec/ncs_navigator/mdes/disposition_code_spec.rb