Sha256: 8672f79b8d1fae1b0537d128efd0f7bbafa686db0770d237684621eb9680a9f8
Contents?: true
Size: 880 Bytes
Versions: 5
Compression:
Stored size: 880 Bytes
Contents
require "spec_helper" describe OpenXml::Docx::Elements::BidiOverride do include ElementTestMacros it_should_use tag: :bdo, name: "bidi_override" for_attribute(:direction) do with_value(:rtl) do it_should_assign_successfully it_should_output "<w:bdo w:val=\"rtl\"/>" end with_value(:ltr) do it_should_assign_successfully it_should_output "<w:bdo w:val=\"ltr\"/>" end with_value(:not_allowed) do it_should_raise_an_exception end end context "with children" do before(:each) do @instance = described_class.new text = OpenXml::Docx::Elements::Text.new("Smucker's Preserves") run = OpenXml::Docx::Elements::Run.new run << text instance << run end it_should_output "<w:bdo>\n <w:r>\n <w:t>Smucker's Preserves</w:t>\n </w:r>\n </w:bdo>", assign: false end end
Version data entries
5 entries across 5 versions & 1 rubygems