Sha256: a52a5824462098eb958feb70198c523ff08285b261a3b0438605c328428ff2b5

Contents?: true

Size: 642 Bytes

Versions: 7

Compression:

Stored size: 642 Bytes

Contents

require File.expand_path('spec_helper', File.dirname(__FILE__))

module Imb

  describe BarMap do

    let(:characters) do
      [
        0x1FE0, 0x001F, 0x001F, 0x001F, 0x0ADB,
        0x01A3, 0x1BC3, 0x1838, 0x012B, 0x0076,
      ]
    end
    let(:barcode) do
      [
        2, 0, 0, 3, 2, 0, 0, 1, 0, 0, 2, 1, 0,
        2, 2, 0, 0, 1, 0, 1, 0, 2, 0, 0, 1, 2,
        3, 1, 1, 3, 2, 1, 3, 1, 3, 0, 3, 3, 3,
        3, 3, 0, 2, 0, 3, 2, 2, 2, 2, 0, 1, 3,
        3, 0, 1, 2, 2, 1, 3, 0, 3, 1, 0, 1, 0,
      ]
    end
    let(:bar_map) {BarMap.new}

    specify do
      bar_map.barcode(characters).should == barcode
    end

  end

end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
USPS-intelligent-barcode-0.2.3 spec/BarMap_spec.rb
USPS-intelligent-barcode-0.2.2 spec/BarMap_spec.rb
USPS-intelligent-barcode-0.2.1 spec/BarMap_spec.rb
USPS-intelligent-barcode-0.2.0 spec/BarMap_spec.rb
USPS-intelligent-barcode-0.1.2 spec/BarMap_spec.rb
USPS-intelligent-barcode-0.1.1 spec/BarMap_spec.rb
USPS-intelligent-barcode-0.1.0 spec/BarMap_spec.rb