public void llist2_Delete_Start_DeleteValue_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); ll.DeleteStart(); Assert.AreEqual("2 9 5 6 7 ", ll.ToString()); }
public void llist2_Init_error() { LList2 ll = new LList2(); ll.Init(new int[] { 1, 2, 9, 5, 6, 2 }); LList1 al1 = new LList1(); al1.Init(new int[] { 1, 2, 9, 5, 6, 2 }); // llist al1 = new llist(new int[] { 1, 2, 9, 5, 6, 2 }); Assert.AreEqual(ll.ToString(), al1.ToString()); //Assert.AreEqual("1 2 9 5 6 ", al.ToString()); }
public void llist2_AddPosition_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); ll.AddPosition(42, 4); Assert.AreEqual("1 2 9 5 42 6 7 ", ll.ToString()); }
public void llist2_Delete_Position_DeleteValue_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); ll.DeletePos(3); Assert.AreEqual("1 2 9 6 7 ", ll.ToString()); }
public void llist2_AddEnd_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); ll.AddEnd(42); Assert.AreEqual("1 2 9 5 6 7 42 ", ll.ToString()); }
public void llist2_AddStart_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); ll.AddStart(42); Assert.AreEqual("42 1 2 9 5 6 7 ", ll.ToString()); }
public void llist2_Half_Reverse_odd_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); ll.HalfReverse(); Assert.AreEqual("9 2 1 5 6 7 ", ll.ToString()); }
public void llist2_Delete_End_DeleteValue_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); ll.DeleteEnd(); Assert.AreEqual("1 2 9 5 6 ", ll.ToString()); }
public void llist2_Sort_error() { LList2 ll = new LList2(new int[] { 2, 1, 9, 5, 6, 7 }); ll.Sort(); Assert.AreEqual("1 2 5 6 7 9 ", ll.ToString()); }
public void llist2_Set_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); ll.Set(42, 3); Assert.AreEqual("1 2 9 42 6 7 ", ll.ToString()); }
public void llist2_Reverse_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); ll.Reverse(); Assert.AreEqual("7 6 5 9 2 1 ", ll.ToString()); }
public void llist2_Min_Index_error() { LList2 ll = new LList2(new int[] { 0, 2, 9, 5, 6, 7 }); Assert.AreEqual(0, ll.MinIndex()); }
public void llist2_Max_Index_error() { LList2 ll = new LList2(new int[] { 1, 2, 9, 5, 6, 7 }); Assert.AreEqual(2, ll.MaxIndex()); }