Ejemplo n.º 1
0
        public void SearchHeroes_ShouldReturnHeroesWithCorrectName_WhenKnownNameIsPassed()
        {
            HeroesService heroesService = new HeroesService();
            string        name          = "ky";

            IEnumerable <Hero> filtered = heroesService.SearchHeroes(name);

            Assert.AreEqual(1, filtered.Count());
        }
Ejemplo n.º 2
0
        public void SearchHeroes_ShouldReturnEmpty_WhenUnknownNameIsPassed()
        {
            HeroesService heroesService = new HeroesService();

            string name = "boi";

            IEnumerable <Hero> filtered = heroesService.SearchHeroes(name);

            Assert.AreEqual(0, filtered.Count());
        }
Ejemplo n.º 3
0
        public void get_hero()
        {
            HeroesService heroes = new HeroesService();

            var    hero = new Hero();
            string name = "Ma";

            IEnumerable <Hero> filtered = heroes.SearchHeroes(name);

            Assert.AreEqual(1, filtered.Count());
            //get Heroes[Test]
        }