public void TestRetrievePrivateDomainResponse() { string json = @"{ ""metadata"": { ""guid"": ""face0158-42ca-4003-8a48-d1c56a793ac8"", ""url"": ""/v2/private_domains/face0158-42ca-4003-8a48-d1c56a793ac8"", ""created_at"": ""2015-04-16T12:04:14+00:00"", ""updated_at"": null }, ""entity"": { ""name"": ""vcap.me"", ""owning_organization_guid"": ""68378f1b-b6b1-4b89-8614-ff80330b6ae0"", ""owning_organization_url"": ""/v2/organizations/68378f1b-b6b1-4b89-8614-ff80330b6ae0"" } }"; RetrievePrivateDomainResponse obj = Utilities.DeserializeJson <RetrievePrivateDomainResponse>(json); Assert.AreEqual("face0158-42ca-4003-8a48-d1c56a793ac8", TestUtil.ToTestableString(obj.EntityMetadata.Guid), true); Assert.AreEqual("/v2/private_domains/face0158-42ca-4003-8a48-d1c56a793ac8", TestUtil.ToTestableString(obj.EntityMetadata.Url), true); Assert.AreEqual("2015-04-16T12:04:14+00:00", TestUtil.ToTestableString(obj.EntityMetadata.CreatedAt), true); Assert.AreEqual("", TestUtil.ToTestableString(obj.EntityMetadata.UpdatedAt), true); Assert.AreEqual("vcap.me", TestUtil.ToTestableString(obj.Name), true); Assert.AreEqual("68378f1b-b6b1-4b89-8614-ff80330b6ae0", TestUtil.ToTestableString(obj.OwningOrganizationGuid), true); Assert.AreEqual("/v2/organizations/68378f1b-b6b1-4b89-8614-ff80330b6ae0", TestUtil.ToTestableString(obj.OwningOrganizationUrl), true); }
public void TestRetrievePrivateDomainResponse() { string json = @"{ ""metadata"": { ""guid"": ""48e7186a-a872-4c61-ba1f-253cef3ba6f6"", ""url"": ""/v2/private_domains/998a9189-b5dc-4d5a-9376-a57bc030b8dd"", ""created_at"": ""2016-09-02T11:52:05Z"", ""updated_at"": null }, ""entity"": { ""name"": ""vcap.me"", ""owning_organization_guid"": ""48e7186a-a872-4c61-ba1f-253cef3ba6f6"", ""owning_organization_url"": ""/v2/organizations/b43de96c-56b6-48bb-8fd2-6cd3658b3835"", ""shared_organizations_url"": ""/v2/private_domains/998a9189-b5dc-4d5a-9376-a57bc030b8dd/shared_organizations"" } }"; RetrievePrivateDomainResponse obj = Utilities.DeserializeJson <RetrievePrivateDomainResponse>(json); Assert.AreEqual("48e7186a-a872-4c61-ba1f-253cef3ba6f6", TestUtil.ToTestableString(obj.EntityMetadata.Guid), true); Assert.AreEqual("/v2/private_domains/998a9189-b5dc-4d5a-9376-a57bc030b8dd", TestUtil.ToTestableString(obj.EntityMetadata.Url), true); Assert.AreEqual("2016-09-02T11:52:05Z", TestUtil.ToTestableString(obj.EntityMetadata.CreatedAt), true); Assert.AreEqual("", TestUtil.ToTestableString(obj.EntityMetadata.UpdatedAt), true); Assert.AreEqual("vcap.me", TestUtil.ToTestableString(obj.Name), true); Assert.AreEqual("48e7186a-a872-4c61-ba1f-253cef3ba6f6", TestUtil.ToTestableString(obj.OwningOrganizationGuid), true); Assert.AreEqual("/v2/organizations/b43de96c-56b6-48bb-8fd2-6cd3658b3835", TestUtil.ToTestableString(obj.OwningOrganizationUrl), true); Assert.AreEqual("/v2/private_domains/998a9189-b5dc-4d5a-9376-a57bc030b8dd/shared_organizations", TestUtil.ToTestableString(obj.SharedOrganizationsUrl), true); }
public void TestRetrievePrivateDomainResponse() { string json = @"{ ""metadata"": { ""guid"": ""0092b149-ca9d-4e2c-9f36-eab07b08a6d5"", ""url"": ""/v2/private_domains/0092b149-ca9d-4e2c-9f36-eab07b08a6d5"", ""created_at"": ""2016-02-09T10:21:53Z"", ""updated_at"": null }, ""entity"": { ""name"": ""vcap.me"", ""owning_organization_guid"": ""21b05e41-2a93-45aa-8b06-b5512532a29a"", ""owning_organization_url"": ""/v2/organizations/21b05e41-2a93-45aa-8b06-b5512532a29a"", ""shared_organizations_url"": ""/v2/private_domains/0092b149-ca9d-4e2c-9f36-eab07b08a6d5/shared_organizations"" } }"; RetrievePrivateDomainResponse obj = Utilities.DeserializeJson <RetrievePrivateDomainResponse>(json); Assert.AreEqual("0092b149-ca9d-4e2c-9f36-eab07b08a6d5", TestUtil.ToTestableString(obj.EntityMetadata.Guid), true); Assert.AreEqual("/v2/private_domains/0092b149-ca9d-4e2c-9f36-eab07b08a6d5", TestUtil.ToTestableString(obj.EntityMetadata.Url), true); Assert.AreEqual("2016-02-09T10:21:53Z", TestUtil.ToTestableString(obj.EntityMetadata.CreatedAt), true); Assert.AreEqual("", TestUtil.ToTestableString(obj.EntityMetadata.UpdatedAt), true); Assert.AreEqual("vcap.me", TestUtil.ToTestableString(obj.Name), true); Assert.AreEqual("21b05e41-2a93-45aa-8b06-b5512532a29a", TestUtil.ToTestableString(obj.OwningOrganizationGuid), true); Assert.AreEqual("/v2/organizations/21b05e41-2a93-45aa-8b06-b5512532a29a", TestUtil.ToTestableString(obj.OwningOrganizationUrl), true); Assert.AreEqual("/v2/private_domains/0092b149-ca9d-4e2c-9f36-eab07b08a6d5/shared_organizations", TestUtil.ToTestableString(obj.SharedOrganizationsUrl), true); }