public void RemoveTest() { //arrange string a = @"\test"; string b = @"\test1"; string c = @"\test2"; string d = @"\test3"; string expected = a; //act Component f1 = new Folder(a); Component f2 = new Folder(b); Component f3 = new Folder(c); Component f4 = new Folder(d); f1.Add(f2); f2.Add(f3); f3.Add(f4); f3.Remove(f4); f2.Remove(f3); f1.Remove(f2); string actual = f1.AddName(""); //assert Assert.AreEqual(expected, actual); }
public void AddEmptyNameTest() { //arrange string a = ""; string b = @"\test"; string expected = b + a; //act Folder f = new Folder(a); string actual = f.AddName(b); //assert Assert.AreEqual(expected, actual); }