public void CodesTest() { WeatherCodes.Init(); var icon = WeatherCodes.Instance.GetWeatherIcon(800); Assert.AreEqual("http://openweathermap.org/img/w/01d.png", icon); }
public Startup(IConfiguration configuration) { Configuration = configuration; using (var client = new NewsContext()) { client.Database.EnsureDeleted(); client.Database.EnsureCreated(); NewsController.SeedTheCategories(); // NewsController.SeedTheAuthors(); } WeatherCodes.Init(); //Initializing the weathercodes dictionary. }