Sha256: f934adc3ee92619391f5be7d2c89820f134e29400826633bc9f0dadcce79a135
Contents?: true
Size: 549 Bytes
Versions: 5
Compression:
Stored size: 549 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) ll.offences.size.should == 1 ll.offences.first.message.should == 'Line is too long. [80/79]' end it "accepts a line that's 79 characters wide" do ll.inspect('file.rb', ['#' * 79], nil, nil) ll.offences.size.should == 0 end end end end
Version data entries
5 entries across 5 versions & 1 rubygems