Sha256: ff026f8fe24821465c3af89f7ae025829b8d8e040bebd96fb97ded38c47d46a6

Contents?: true

Size: 811 Bytes

Versions: 1

Compression:

Stored size: 811 Bytes

Contents

# coding: utf-8

require File.dirname(__FILE__) + '/spec_helper.rb'

describe ONIX2::Lists, "list method" do

  it "should return a hash containing the ProductForm code list" do
    forms = ONIX2::Lists.list(7)
    expect(forms).to be_a(Hash)
    expect(forms["BB"]).to be_eql("Hardback")
  end

end

describe ONIX2::Lists, "product_form shortcut method" do

  it "should return a hash containing the ProductForm code list" do
    forms = ONIX2::Lists.product_form
    expect(forms).to be_a(Hash)
    expect(forms["BB"]).to be_eql("Hardback")
  end

end

describe ONIX2::Lists, "PRODUCT_FORM shortcut constant" do

  it "should return a hash containing the ProductForm code list" do
    forms = ONIX2::Lists::PRODUCT_FORM
    expect(forms).to be_a(Hash)
    expect(forms["BB"]).to be_eql("Hardback")
  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
onix2-1.0.0 spec/lists_spec.rb