spec/language_spec.rb in lint_trap-0.0.10 vs spec/language_spec.rb in lint_trap-0.0.11

- old
+ new

@@ -65,18 +65,18 @@ end context 'when given an unknown language file' do let(:file){fixture_path('lint.txt')} - it{is_expected.to eq(nil)} + it{is_expected.to eq(described_class::Unknown.new('Text'))} end context 'when given a known language file that is empty' do let(:file){fixture_path('empty.rb')} # Linguist can't figure out what language the empty file is - it{is_expected.to eq(nil)} + it{is_expected.to eq(described_class::Unknown.new)} end end describe '.find' do subject(:language){described_class.find(language_name)} @@ -142,9 +142,9 @@ end context 'when given an invalid language' do let(:language_name){'invalid language'} - it{is_expected.to eq(nil)} + it{is_expected.to eq(described_class::Unknown.new(language_name))} end end end