public void GetCurrentTrackIndex_ThreeTracksAdded_NextTrackCalledTwice_ExpectedIndexEqualsTwo() { var myQueue = new PlayqueueHandler(); ITrack t1 = new Track(); ITrack t2 = new Track(); ITrack t3 = new Track(); myQueue.AddToPlayQueue(t1); myQueue.AddToPlayQueue(t2); myQueue.AddToPlayQueue(t3); myQueue.GetNextTrack(); myQueue.GetNextTrack(); Assert.AreEqual(2,myQueue.GetCurrentTrackIndex()); }
public void GetCurrentTrackIndex_TwoTracksAdded_NextTrackCalledFiveTimesPrevCalledFiveTimesNextCalledFiveTimes_ExpectedIndexEqualsTwo() { var myQueue = new PlayqueueHandler(); ITrack t1 = new Track(); ITrack t2 = new Track(); myQueue.AddToPlayQueue(t1); myQueue.AddToPlayQueue(t2); myQueue.GetNextTrack(); myQueue.GetNextTrack(); myQueue.GetNextTrack(); myQueue.GetNextTrack(); myQueue.GetNextTrack(); myQueue.GetPrevTrack(); myQueue.GetPrevTrack(); myQueue.GetPrevTrack(); myQueue.GetPrevTrack(); myQueue.GetPrevTrack(); myQueue.GetNextTrack(); myQueue.GetNextTrack(); myQueue.GetNextTrack(); myQueue.GetNextTrack(); myQueue.GetNextTrack(); Assert.AreEqual(2, myQueue.GetCurrentTrackIndex()); }