public async Task ResetSolutionBackupServiceCredentialsAsync_ValidParameters_ExpectedClientCall() { IUKFastDRaaSClient client = Substitute.For <IUKFastDRaaSClient>(); var req = new ResetBackupServiceCredentialsRequest() { Password = "******" }; var ops = new BackupServiceOperations <BackupService>(client); var solutionID = "00000000-0000-0000-0000-000000000000"; await ops.ResetSolutionBackupServiceCredentialsAsync(solutionID, req); await client.Received() .PostAsync($"/draas/v1/solutions/{solutionID}/backup-service/reset-credentials", req); }
public async Task ResetSolutionBackupServiceCredentialsAsync(string solutionID, ResetBackupServiceCredentialsRequest req) { if (string.IsNullOrWhiteSpace(solutionID)) { throw new UKFastClientValidationException("Invalid solution id"); } await this.Client.PostAsync($"/draas/v1/solutions/{solutionID}/backup-service/reset-credentials", req); }