Exemplo n.º 1
0
    public void TestResetSpeakerTime()
    {
        var instance = new ListOfSpeakersViewModel();

        instance.SpeakerTime = new TimeSpan(0, 0, 30);
        instance.AddSpeaker("Speaker 1");
        instance.NextSpeaker();
        instance.ResumeSpeaker();
        instance.AddSpeakerSeconds(-10);
        Assert.IsTrue(instance.RemainingSpeakerTime.TotalSeconds <= 20);
        instance.ResetSpeakerTime();
        Assert.AreEqual(30, instance.RemainingSpeakerTime.TotalSeconds, 0.5);
    }