Sha256: 2eb745a6488a614bb8c4e1f1541cfbc7f9d4b72ec29c4971e82a4011caf943a8

Contents?: true

Size: 720 Bytes

Versions: 2

Compression:

Stored size: 720 Bytes

Contents

require "spec_helper"

describe OpenXml::Docx::Elements::WordProcessingDrawingSimplePosition do
  include ElementTestMacros

  it_should_use tag: :simplePos, name: "word_processing_drawing_simple_position"

  with_no_attributes_set do
    it_should_output "<wp:simplePos/>", assign: false
  end

  for_attribute(:x) do
    with_value([1234, -1234])do
      it_should_assign_successfully
      it_should_output_regular_xml
    end

    with_value("hey") do
      it_should_raise_an_exception
    end
  end

  for_attribute(:y) do
    with_value([1234, -1234])do
      it_should_assign_successfully
      it_should_output_regular_xml
    end

    with_value("hey") do
      it_should_raise_an_exception
    end
  end

end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
openxml-docx-0.10.1 spec/elements/word_processing_drawing_simple_position_spec.rb
openxml-docx-0.10.0 spec/elements/word_processing_drawing_simple_position_spec.rb