Updated UnitTests

This commit is contained in:
2025-10-27 16:29:31 +01:00
parent 4d05976ff6
commit 69816d0c02
56 changed files with 247 additions and 246 deletions

View File

@@ -59,7 +59,7 @@ namespace Cloudflare.Zones.Tests.ZoneSettingsExtensions
// Act
#pragma warning disable CS0618
var response = await client.EditMultipleZoneSettings(_request, TestContext.CancellationTokenSource.Token);
var response = await client.EditMultipleZoneSettings(_request, TestContext.CancellationToken);
#pragma warning restore CS0618
// Assert

View File

@@ -53,7 +53,7 @@ namespace Cloudflare.Zones.Tests.ZoneSettingsExtensions
var client = GetClient();
// Act
var response = await client.EditZoneSetting(_request, TestContext.CancellationTokenSource.Token);
var response = await client.EditZoneSetting(_request, TestContext.CancellationToken);
// Assert
Assert.IsNotNull(response);
@@ -80,7 +80,7 @@ namespace Cloudflare.Zones.Tests.ZoneSettingsExtensions
var client = GetClient();
// Act
var response = await client.EditZoneSetting(_request, TestContext.CancellationTokenSource.Token);
var response = await client.EditZoneSetting(_request, TestContext.CancellationToken);
// Assert
Assert.IsNotNull(response);
@@ -105,7 +105,7 @@ namespace Cloudflare.Zones.Tests.ZoneSettingsExtensions
var client = GetClient();
// Act & Assert
await Assert.ThrowsExactlyAsync<ArgumentException>(async () => await client.EditZoneSetting(request, TestContext.CancellationTokenSource.Token));
await Assert.ThrowsExactlyAsync<ArgumentException>(async () => await client.EditZoneSetting(request, TestContext.CancellationToken));
}
private ICloudflareClient GetClient()

View File

@@ -49,7 +49,7 @@ namespace Cloudflare.Zones.Tests.ZoneSettingsExtensions
// Act
#pragma warning disable CS0618
var response = await client.GetAllZoneSettings(ZoneId, TestContext.CancellationTokenSource.Token);
var response = await client.GetAllZoneSettings(ZoneId, TestContext.CancellationToken);
#pragma warning restore CS0618
// Assert

View File

@@ -45,7 +45,7 @@ namespace Cloudflare.Zones.Tests.ZoneSettingsExtensions
var client = GetClient();
// Act
var response = await client.GetZoneSetting<SSL>(ZoneId, TestContext.CancellationTokenSource.Token);
var response = await client.GetZoneSetting<SSL>(ZoneId, TestContext.CancellationToken);
// Assert
Assert.IsNotNull(response);
@@ -69,7 +69,7 @@ namespace Cloudflare.Zones.Tests.ZoneSettingsExtensions
var client = GetClient();
// Act & Assert
await Assert.ThrowsExactlyAsync<ArgumentException>(async () => await client.GetZoneSetting<TestSetting>(ZoneId, TestContext.CancellationTokenSource.Token));
await Assert.ThrowsExactlyAsync<ArgumentException>(async () => await client.GetZoneSetting<TestSetting>(ZoneId, TestContext.CancellationToken));
}
private ICloudflareClient GetClient()