test/yao/resources/test_networking_agents.rb in yao-0.19.0 vs test/yao/resources/test_networking_agents.rb in yao-0.20.0

- old
+ new

@@ -1,6 +1,7 @@ class TestNetworkingAgents < TestYaoResource + include RestfullyAccessibleStub def test_networking_agents # https://docs.openstack.org/api-ref/network/v2/?expanded=list-all-agents-detail#list-all-agents params = { @@ -78,7 +79,14 @@ assert_equal("N/A", agent.topic) assert_equal(Time.parse("2017-09-12 19:40:08"), agent.heartbeat_timestamp) assert_equal(Time.parse("2017-09-12 19:35:38"), agent.created_at) assert_equal(Time.parse("2017-09-12 19:35:38"), agent.started_at) + end + + def test_delete + stub = stub_delete_request("https://example.com:12345/agents/test-id") + agents = Yao::NetworkingAgents.new({"id" => "test-id"}) + assert_equal({}, agents.delete) + assert_requested(stub) end end