public void ClearTest() { RollingWindow <int> rollingWindow = new RollingWindow <int>(5); for (int i = 0; i < rollingWindow.WindowSize; i++) { rollingWindow.Add(i); } Assert.AreEqual(rollingWindow.WindowSize, rollingWindow.Count); rollingWindow.Clear(); Assert.AreEqual(0, rollingWindow.Count); }
public void ClearTest() { RollingWindow<int> rollingWindow = new RollingWindow<int>(5); for (int i = 0; i < rollingWindow.WindowSize; i++) rollingWindow.Add(i); Assert.AreEqual(rollingWindow.WindowSize, rollingWindow.Count); rollingWindow.Clear(); Assert.AreEqual(0, rollingWindow.Count); }