private async Task Given_ACountryInTheDatabase_When_GetCountryIsInvokedWithTheCountryId_Then_TheCountryIsReturned(Country country)
        {
            try
            {
                var countryReturned = await CountriesClient.GetCountry(country.Id);

                Assert.AreEqual(country.Alpha2Code, countryReturned.Alpha2Code);
                Assert.AreEqual(country.CreatedByUserId, countryReturned.CreatedByUserId);
                Assert.AreEqual(country.CreatedOn, countryReturned.CreatedOn);
                Assert.AreEqual(country.Id, countryReturned.Id);
                Assert.AreEqual(country.LastUpdatedByUserId, countryReturned.LastUpdatedByUserId);
                Assert.AreEqual(country.LastUpdatedOn, countryReturned.LastUpdatedOn);
                Assert.AreEqual(country.FullName, countryReturned.FullName);
                Assert.AreEqual(country.PhoneNumberRegex, countryReturned.PhoneNumberRegex);
                Assert.AreEqual(country.PostalCodeRegex, countryReturned.PostalCodeRegex);
            }
            catch (Exception e)
            {
                Assert.Fail($"{e.Message}\n{e.StackTrace}");
            }
        }
        private async Task Given_ACountryIdInTheDatabase_When_DeleteCountryIsInvokedWithTheCountryId_Then_TheCountryIsDeleted(int countryId)
        {
            try
            {
                await CountriesClient.DeleteCountry(countryId);

                var softDeletedAddress = await CountriesClient.GetCountry(countryId);

                Assert.IsTrue(softDeletedAddress.EffectiveEndDate > DateTime.UtcNow.AddSeconds(-5) && softDeletedAddress.EffectiveEndDate <= DateTime.UtcNow);

                var uri = new Uri(Path.Combine(ConfigurationManager.AppSettings[Constants.ApiEndpointKey], Routes.CountryV1BaseRoute, "force", countryId.ToString()));

                using (var client = new HttpClient())
                {
                    using (var response = await client.DeleteAsync(uri))
                    {
                        if (!response.IsSuccessStatusCode)
                        {
                            throw new HttpRequestException(response.Content.ToString());
                        }
                    }
                }
            }
            catch (HttpRequestException e)
            {
                Assert.Fail($"{e.Message}\n{e.StackTrace}");
            }

            try
            {
                await CountriesClient.GetCountry(countryId);

                Assert.Fail($"Address id: {countryId} was found after it should have been deleted.");
            }
            catch (ApiInvokerException)
            {
            }
        }