Beispiel #1
0
        public void GetNumericCodeByCountryName()
        {
            string result = CountryUtils.GetNumericCodeByCountry("United States of America");

            Assert.IsNotNull(result);
            Assert.AreEqual("840", result);
        }
Beispiel #2
0
        public void GetNumericCodeByNumericCode()
        {
            string result = CountryUtils.GetNumericCodeByCountry("840");

            Assert.IsNotNull(result);
            Assert.AreEqual("840", result);
        }
        public void GetNetherlandsAntillesNumericCodeByCountryCode()
        {
            string result = CountryUtils.GetNumericCodeByCountry("AN");

            Assert.IsNotNull(result);
            Assert.AreEqual("530", result);
        }
Beispiel #4
0
        public void GetNumericCodeByNonExistingCountryName()
        {
            string result = CountryUtils.GetNumericCodeByCountry("Fake Country Name");

            Assert.IsNull(result);
        }