Sha256: 56501982678df62d94ac498fe2283547cd7f396cfd5ab91f2c008024db4b5b36

Contents?: true

Size: 797 Bytes

Versions: 10

Compression:

Stored size: 797 Bytes

Contents

require "test_helper"

module Csscss::Parser
  module BorderColor
    describe BorderColor do
      include CommonParserTests

      before do
        @parser = Parser.new
        @trans = Transformer.new
      end

      it "converts shorthand rules to longhand" do
        trans("#fff transparent black rgb(1, 2, 3)").must_equal([
          dec("border-top-color", "#fff"),
          dec("border-right-color", "transparent"),
          dec("border-bottom-color", "black"),
          dec("border-left-color", "rgb(1, 2, 3)")
        ])

        trans("#fff black").must_equal([
          dec("border-top-color", "#fff"),
          dec("border-right-color", "black"),
          dec("border-bottom-color", "#fff"),
          dec("border-left-color", "black")
        ])
      end
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
csscss-1.3.3 test/csscss/parser/border_color_test.rb
csscss-1.3.2 test/csscss/parser/border_color_test.rb
csscss-1.3.1 test/csscss/parser/border_color_test.rb
csscss-1.3.0 test/csscss/parser/border_color_test.rb
csscss-1.2.0 test/csscss/parser/border_color_test.rb
csscss-1.1.0 test/csscss/parser/border_color_test.rb
csscss-1.0.0 test/csscss/parser/border_color_test.rb
csscss-0.2.1 test/csscss/parser/border_color_test.rb
csscss-0.2.0 test/csscss/parser/border_color_test.rb
csscss-0.1.0 test/csscss/parser/border_color_test.rb