spec/rubocop/cops/ascii_identifiers_spec.rb in rubocop-0.7.2 vs spec/rubocop/cops/ascii_identifiers_spec.rb in rubocop-0.8.0

- old
+ new

@@ -7,19 +7,18 @@ describe AsciiIdentifiers do let(:ascii) { AsciiIdentifiers.new } it 'registers an offence for a variable name with non-ascii chars' do inspect_source(ascii, - 'file.rb', - ['älg = 1']) + ['# encoding: utf-8', + 'älg = 1']) expect(ascii.offences.size).to eq(1) expect(ascii.offences.map(&:message)) - .to eq([AsciiIdentifiers::ERROR_MESSAGE]) + .to eq([AsciiIdentifiers::MSG]) end it 'accepts identifiers with only ascii chars' do inspect_source(ascii, - 'file.rb', ['x.empty?']) expect(ascii.offences).to be_empty end end end