예제 #1
0
        public void CreateDirWhenDirExists()
        {
            Dir422 dir = _root.CreateDir("Dir1");

            Assert.NotNull(dir);
            Assert.AreEqual("Dir1", dir.Name);
            Assert.AreEqual("FSROOT", dir.Parent.Name);
        }
예제 #2
0
        public void CreateDirWithEmptyNameShouldReturnNull()
        {
            StdFSDir dir = new StdFSDir();

            dir = (StdFSDir)dir.CreateDir("");
            Assert.Null(dir);
        }
예제 #3
0
        public void CreateDirWithBackwardSlashInNameShouldReturnNull()
        {
            StdFSDir dir = new StdFSDir();

            dir = (StdFSDir)dir.CreateDir("\\bad\\name");
            Assert.Null(dir);
        }
예제 #4
0
        public void CreateDirS()
        {
            StdFSDir dir = new StdFSDir(good_path, false);

            dir.CreateDir("d6");

            Dir422 gotten_file = dir.GetDir("d6");

            Assert.AreEqual("d6", gotten_file.Name);
        }