Sha256: f23b4f012c6c14774cfd31307be3c433ff087cfd2d36bedffd2ede1c69814b7c

Contents?: true

Size: 1.09 KB

Versions: 1

Compression:

Stored size: 1.09 KB

Contents

class TestLoadBalancerPoolMember < TestYaoResource
  def test_loadbalancer_pool_member
    params = {
      "monitor_port" => 8080,
      "name" => "web-server-1",
      "weight" => 20,
      "admin_state_up" => true,
      "created_at" => "2017-05-11T17:21:34",
      "provisioning_status" => "ACTIVE",
      "monitor_address" => nil,
      "updated_at" => "2017-05-11T17:21:37",
      "address" => "192.0.2.16",
      "protocol_port" => 80,
      "operating_status" => "NO_MONITOR"
    }

    member = Yao::Resources::LoadBalancerPoolMember.new(params)
    assert_equal(member.monitor_port, 8080)
    assert_equal(member.name, "web-server-1")
    assert_equal(member.weight, 20)
    assert_equal(member.admin_state_up, true)
    assert_equal(member.created, Time.parse("2017-05-11T17:21:34"))
    assert_equal(member.provisioning_status, "ACTIVE")
    assert_equal(member.monitor_address, nil)
    assert_equal(member.updated, Time.parse("2017-05-11T17:21:37"))
    assert_equal(member.address, "192.0.2.16")
    assert_equal(member.protocol_port, 80)
    assert_equal(member.operating_status, "NO_MONITOR")
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
yao-0.8.0 test/yao/resources/test_loadbalancer_pool_member.rb