Sha256: fe3f6e7e8d47324e25ab4c5ab2e5f2e81f5d8382c5f22162eb5042e0f8913c58

Contents?: true

Size: 391 Bytes

Versions: 7

Compression:

Stored size: 391 Bytes

Contents

require 'test_helper'

class BindingsTest < MiniTest::Spec
  describe "TextRef#read" do
    def parse_xml(xml); Nokogiri::XML(xml).root; end
    
    before do
      @ref = Representable::XML::TextBinding.new(Representable::Definition.new(:song))
    end
    
    it "returns found value" do
      assert_equal "Unkoil", @ref.read(parse_xml("<a><song>Unkoil</song></a>"))
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
representable-1.0.1 test/bindings_test.rb
representable-1.0.0 test/bindings_test.rb
representable-0.13.1 test/bindings_test.rb
representable-0.13.0 test/bindings_test.rb
representable-0.12.0 test/bindings_test.rb
representable-0.11.0 test/bindings_test.rb
representable-0.10.3 test/bindings_test.rb