Sha256: c3e0737eedbc4ce55814f8532c1dffd4e702ded1767448554248b3702f1b2871

Contents?: true

Size: 464 Bytes

Versions: 14

Compression:

Stored size: 464 Bytes

Contents

class TestResourceBase < TestYaoResource
  def setup
    stub(Yao::Resources::Base).get { Yao::Resources::Base.new({"id" => "foor", "name" => "bar"}) }
  end

  def test_friendly_attributes
    base = Yao::Resources::Base.new({"id" => "foor"})
    base.class.friendly_attributes(:name)
    assert_equal("bar", base.name)

    base = Yao::Resources::Base.new({"name" => "bar"})
    base.class.friendly_attributes(:name)
    assert_equal("bar", base.name)
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
yao-0.13.4 test/yao/resources/test_base.rb
yao-0.13.3 test/yao/resources/test_base.rb
yao-0.13.2 test/yao/resources/test_base.rb
yao-0.13.1 test/yao/resources/test_base.rb
yao-0.13.0 test/yao/resources/test_base.rb
yao-0.12.0 test/yao/resources/test_base.rb
yao-0.11.3 test/yao/resources/test_base.rb
yao-0.11.2 test/yao/resources/test_base.rb
yao-0.11.1 test/yao/resources/test_base.rb
yao-0.11.0 test/yao/resources/test_base.rb
yao-0.10.1 test/yao/resources/test_base.rb
yao-0.10.0 test/yao/resources/test_base.rb
yao-0.9.1 test/yao/resources/test_base.rb
yao-0.9.0 test/yao/resources/test_base.rb