Beispiel #1
0
        public void IPTest5()
        {
            string ip = "qwe.rt.yui.op";

            IPResolver.IPInfo expected = new IPResolver.IPInfo()
            {
                Organization = "Not Found"
            };
            IPResolver.IPInfo result = IPResolver.GetInfo(ip).Result;
            Assert.AreEqual(expected, result);
        }
Beispiel #2
0
        public void IPTest2()
        {
            string ip = "185.53.179.6";

            IPResolver.IPInfo expected = new IPResolver.IPInfo()
            {
                Country   = "Germany",
                Latitude  = 51.2993m,
                Longitude = 9.490997m
            };
            IPResolver.IPInfo result = IPResolver.GetInfo(ip).Result;
            Assert.AreEqual(expected, result);
        }
Beispiel #3
0
        public void IPTest3()
        {
            string ip = "167.40.79.24";

            IPResolver.IPInfo expected = new IPResolver.IPInfo()
            {
                Country   = "Canada",
                Latitude  = 43.6319m,
                Longitude = -79.3716m
            };
            IPResolver.IPInfo result = IPResolver.GetInfo(ip).Result;
            Assert.AreEqual(expected, result);
        }
Beispiel #4
0
        public void IPTest1()
        {
            string ip = "172.217.0.99";

            IPResolver.IPInfo expected = new IPResolver.IPInfo()
            {
                Country   = "United States",
                Latitude  = 37.75101m,
                Longitude = -97.822m
            };
            IPResolver.IPInfo result = IPResolver.GetInfo(ip).Result;
            Assert.AreEqual(expected, result);
        }
Beispiel #5
0
        public void IPTest4()
        {
            string ip = "70.35.123.53";

            IPResolver.IPInfo expected = new IPResolver.IPInfo()
            {
                City          = "Redmond",
                Country       = "United States",
                Latitude      = 47.6718m,
                Longitude     = -122.1232m,
                StateProvince = "WA"
            };
            IPResolver.IPInfo result = IPResolver.GetInfo(ip).Result;
            Assert.AreEqual(expected, result);
        }