Sha256: 104089fc2a2fc560c6cc45e037dc461e7cc1cfd8718253c22a28e3fbd8d77274
Contents?: true
Size: 586 Bytes
Versions: 4
Compression:
Stored size: 586 Bytes
Contents
# encoding: utf-8 require 'spec_helper' module Rubocop module Cop describe SpaceAfterSemicolon do let(:space) { SpaceAfterSemicolon.new } it 'registers an offence for semicolon without space after it' do inspect_source(space, ['x = 1;y = 2']) expect(space.offences.map(&:message)).to eq( ['Space missing after semicolon.']) end it 'does not crash if semicolon is the last character of the file' do inspect_source(space, ['x = 1;']) expect(space.offences.map(&:message)).to be_empty end end end end
Version data entries
4 entries across 4 versions & 1 rubygems