Exemplo n.º 1
0
        public void TestMethod1()
        {
            IDate fakeDateProvider = new FakeDateProvider(new DateTime(year: 2018, month: 8, day: 18)); //Samedi

            Messages mess = new Messages(fakeDateProvider, 9, 13, 18);

            string result = mess.HelloMessages();

            Assert.IsTrue(result.Contains("Bon Week-End"));
        }
Exemplo n.º 2
0
        public void TestMethod2()
        {
            IDate fakeDateProvider = new FakeDateProvider(new DateTime(year: 2018, month: 8, day: 21, hour: 10, minute: 0, second: 0)); //Mardi 10h

            Messages mess = new Messages(fakeDateProvider, 9, 13, 18);

            string result = mess.HelloMessages();

            Assert.IsTrue(result.Contains("Bonjour"));
        }