Sha256: bf0525adae32715045f5b4bbc38b0d7d8a73972a1d919c694d66cea2d8a7cb6d

Contents?: true

Size: 414 Bytes

Versions: 54

Compression:

Stored size: 414 Bytes

Contents

require 'rubygems'
require 'rubyXL'

describe RubyXL::Color do
  describe '.validate_color' do
    it 'should return true if a valid hex color without a # is passed' do
      RubyXL::Color.validate_color('0fbCAd').should == true
    end

    it 'should cause an error if an invalid hex color code or one with a # is passed' do
      lambda {RubyXL::Color.validate_color('#G')}.should raise_error
    end
  end
end

Version data entries

54 entries across 54 versions & 4 rubygems

Version Path
thunderboltlabs-rubyXL-1.2.10.2 spec/lib/color_spec.rb
thunderboltlabs-rubyXL-1.2.10.1 spec/lib/color_spec.rb
rubyXL-1.2.10 spec/lib/color_spec.rb
rubyXL-1.2.9 spec/lib/color_spec.rb
rubyXL-1.2.8 spec/lib/color_spec.rb
rubyXL-1.2.7 spec/lib/color_spec.rb
rubyXL-1.2.6 spec/lib/color_spec.rb
rubyXL-1.2.5 spec/lib/color_spec.rb
rubyXL-1.2.4 spec/lib/color_spec.rb
rubyXL-1.2.3 spec/lib/color_spec.rb
rubyXL-1.2.2 spec/lib/color_spec.rb
rubyXL-1.2.1 spec/lib/color_spec.rb
rubyXL-1.2.0 spec/lib/color_spec.rb
rubyXL-1.1.12 spec/lib/color_spec.rb
rubyXL-1.1.11 spec/lib/color_spec.rb
rubyXL-1.1.10 spec/lib/color_spec.rb
rubyXL-1.1.9 spec/lib/color_spec.rb
rubyXL-1.1.8 spec/lib/color_spec.rb
rubyXL-1.1.7 spec/lib/color_spec.rb
rubyXL-1.1.6 spec/lib/color_spec.rb