Esempio n. 1
0
        public void TestAttemptToThrowBurnedCelebBackIntoHat()
        {
            Celeb celeb = new Celeb("Danny Dyer");

            celeb.Burn();
            celeb.Invoking(c => c.PutBackIntoHat())
            .Should().Throw <InvalidOperationException>();
        }
Esempio n. 2
0
        public void CelebBurned(int celebId)
        {
            Celeb celeb = _context.Celeb.Single(c => c.Id == celebId);

            celeb.Burn();
            _context.Celeb.Update(celeb);
            _context.SaveChanges();
        }
Esempio n. 3
0
        public void TestGetNullBackIfNoneInHat()
        {
            Game game = new Game();

            var geezer = new Celeb("Danny Dyer");

            game.AddCeleb(geezer);

            var geoff = new Celeb("Geoff Capes");

            game.AddCeleb(geoff);

            geezer.Guess();
            geoff.Burn();

            game.GetRandomCelebFromHat().Should().BeNull();
        }