Beispiel #1
0
        public void PrintDetails()
        {
            Location    location = new Location("New York");
            WeatherData wm       = WeatherMap.Instance();

            checked { wm.PrintDetails(); } // checks that function initialized
        }
Beispiel #2
0
        public void GetWeatherData()
        {
            Location    location = new Location("New York");
            WeatherMap  wm       = WeatherMap.Instance();
            WeatherData wd       = wm.GetWeatherData(location);

            Assert.AreEqual(location.City, wd.Location.City);
        }