Sha256: e8093736f5611ad2bfcc7ce5777148b58c92a21af183294c7a8afa76d5f885fe
Contents?: true
Size: 561 Bytes
Versions: 10
Compression:
Stored size: 561 Bytes
Contents
# encoding: utf-8 require 'spec_helper' module Rubocop module Cop describe LineLength do let(:ll) { LineLength.new } it "registers an offence for a line that's 80 characters wide" do ll.inspect('file.rb', ['#' * 80], nil, nil) expect(ll.offences.size).to eq(1) expect(ll.offences.first.message).to eq('Line is too long. [80/79]') end it "accepts a line that's 79 characters wide" do ll.inspect('file.rb', ['#' * 79], nil, nil) expect(ll.offences).to be_empty end end end end
Version data entries
10 entries across 10 versions & 1 rubygems