public void RenameTest() { string fname = "test123.txt"; string filePath = Path.Combine(_testDirectory, fname); File target = new File(filePath); target.Create(); string fname2 = "test123d.txt"; string filePath2 = Path.Combine(_testDirectory, fname2); target.Rename(filePath2); Assert.IsTrue(System.IO.File.Exists(filePath2), "File should exist"); Assert.IsFalse(System.IO.File.Exists(filePath), "File should not exist"); Assert.AreEqual(target.Path, filePath2, "File name should be equal"); }