/* * Copyright 2014 VMware, Inc. All rights reserved. Licensed under the Apache v2 License. */ package govcd import ( . "gopkg.in/check.v1" ) func (s *S) Test_FindCatalog(c *C) { // Get the Org populated testServer.Response(200, nil, orgExample) org, err := s.vdc.GetVDCOrg() _ = testServer.WaitRequest() testServer.Flush() c.Assert(err, IsNil) // Find Catalog testServer.Response(200, nil, catalogExample) cat, err := org.FindCatalog("Public Catalog") _ = testServer.WaitRequest() testServer.Flush() c.Assert(err, IsNil) c.Assert(cat.Catalog.Description, Equals, "vCHS service catalog") } var orgExample = ` OrganizationName `