Sha256: 71d655cc52f09207275e43c9d654e8d8fee4fae0f85ae50696f81ef743f918a2

Contents?: true

Size: 701 Bytes

Versions: 6

Compression:

Stored size: 701 Bytes

Contents

require "spec_helper"

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

  it_should_use tag: :wrapTopAndBottom, name: "word_processing_drawing_wrap_top_and_bottom"

  for_attribute(:distance_from_bottom) do
    with_value(1) do
      it_should_assign_successfully
      it_should_output "<wp:wrapTopAndBottom distB=\"1\"/>"
    end

    with_value(-1) do
      it_should_raise_an_exception
    end
  end

  for_attribute(:distance_from_top) do
    with_value(1) do
      it_should_assign_successfully
      it_should_output "<wp:wrapTopAndBottom distT=\"1\"/>"
    end

    with_value(-1) do
      it_should_raise_an_exception
    end
  end

end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
openxml-docx-0.10.6 spec/elements/word_processing_drawing_wrap_top_and_bottom_spec.rb
openxml-docx-0.10.5 spec/elements/word_processing_drawing_wrap_top_and_bottom_spec.rb
openxml-docx-0.10.4 spec/elements/word_processing_drawing_wrap_top_and_bottom_spec.rb
openxml-docx-0.10.3 spec/elements/word_processing_drawing_wrap_top_and_bottom_spec.rb
openxml-docx-0.10.2 spec/elements/word_processing_drawing_wrap_top_and_bottom_spec.rb
openxml-docx-0.10.1 spec/elements/word_processing_drawing_wrap_top_and_bottom_spec.rb