public async Task UpdateServerMetadataWithEmptyImageIdThrows() { var metadata = new Dictionary<string, string>() { { "item1", "value1" } }; var client = new ComputeServiceClient(GetValidCreds(), "Nova", CancellationToken.None, this.ServiceLocator); await client.UpdateServerMetadata(string.Empty, metadata); }
public async Task UpdateServerMetadataWithNullMetadataThrows() { var client = new ComputeServiceClient(GetValidCreds(), "Nova", CancellationToken.None, this.ServiceLocator); await client.UpdateServerMetadata("12345", null); }
public async Task CanUpdateServerMetadata() { var metadata = new Dictionary<string, string>() { { "item1", "value1" } }; this.ServicePocoClient.UpdateServerMetadataDelegate = async (flavorId, meta) => { await Task.Run(() => { Assert.AreEqual(flavorId, "12345"); Assert.AreEqual(metadata, meta); }); }; var client = new ComputeServiceClient(GetValidCreds(), "Nova", CancellationToken.None, this.ServiceLocator); await client.UpdateServerMetadata("12345", metadata); }