Exemplo n.º 1
0
        private void RetrieveByKey(ICountriesRepository repository)
        {
            string key                   = "dz";
            string expected_code         = "ALG";
            string expected_country_name = "Algeria";

            Country country = repository.GetByKey(key);

            Assert.NotNull(country);
            Assert.Equal(expected_code, country.Code);
            Assert.Equal(expected_country_name, country.Name);
        }
Exemplo n.º 2
0
 private async Task GetCountryCommandExecuted(object parameter)
 {
     Country = await Task.FromResult(_repository.GetByKey(parameter.ToString()));
 }