public void TestSetCreationTime() { var tempLongPathFilename = longPathRoot.Combine(Pri.LongPath.Path.GetRandomFileName()); tempLongPathFilename.CreateDirectory(); Assert.IsTrue(tempLongPathFilename.Exists()); try { var dateTime = DateTime.Now.AddDays(1); Directory.SetCreationTime(tempLongPathFilename, dateTime); var di = new DirectoryInfo(tempLongPathFilename); Assert.AreEqual(di.CreationTime, dateTime); } finally { Directory.Delete(tempLongPathFilename); } }