Esempio n. 1
0
        public void TestSetCurrentDirectory()
        {
            var originalDir = Directory.GetCurrentDirectory();

            try {
                Assert.Throws <NotSupportedException>(() => Directory.SetCurrentDirectory(longPathDirectory));
            }
            finally {
                Assert.Throws <NotSupportedException>(() => Directory.SetCurrentDirectory(originalDir));
            }
        }
Esempio n. 2
0
        public void TestCurrentDirectory()
        {
            var di = new DirectoryInfo(".");

            Assert.AreEqual(di.FullName, Directory.GetCurrentDirectory());
        }