Exemplo n.º 1
0
        public static void TestGetAccountMemberDetailsAsync()
        {
            using (var client = new CloudFlareClient(Credentials.Credentials.Authentication))
            {
                var accounts             = client.GetAccountsAsync().Result;
                var accountMembers       = client.GetAccountMembersAsync(accounts.Result.First().Id).Result;
                var accountMemberDetails = client.GetAccountMemberDetailsAsync(accounts.Result.First().Id, accountMembers.Result.First().Id).Result;

                Assert.NotNull(accountMemberDetails);
                Assert.Empty(accountMemberDetails.Errors);
                Assert.True(accountMemberDetails.Success);
            }
        }
Exemplo n.º 2
0
        public async Task TestGetAccountMemberDetailsAsync()
        {
            using var client = new CloudFlareClient(Credentials.Credentials.Authentication);
            var accounts = await client.GetAccountsAsync();

            var accountMembers = await client.GetAccountMembersAsync(accounts.Result.First().Id);

            var accountMemberDetails = client.GetAccountMemberDetailsAsync(accounts.Result.First().Id, accountMembers.Result.First().Id).Result;

            Assert.NotNull(accountMemberDetails);
            Assert.True(accountMemberDetails.Success);
            if (accountMemberDetails.Errors != null)
            {
                Assert.Empty(accountMemberDetails.Errors);
            }
        }