Exemplo n.º 1
0
        public void TargetDir_OneSlash()
        {
            string targetDir   = @"C:\Program Files (x86)\Brown and Caldwell\Project Folder Tool\";
            string expectedDir = @"C:\Program Files (x86)\Brown and Caldwell\Project Folder Tool\";

            Assert.AreEqual(expectedDir, AddToPath.cleanTargetDir(targetDir));
        }
Exemplo n.º 2
0
        public void RemovePath_NotInPath()
        {
            string targetDir   = @"C:\Program Files (x86)\Brown and Caldwell\Project Folder Tool\";
            string currentPath = @"C:\Program Files\dotnet\;";
            string newPath     = AddToPath.removeFromPath(currentPath, targetDir);

            Assert.AreEqual(@"C:\Program Files\dotnet\;", newPath);
        }
Exemplo n.º 3
0
        public void AddPath_AlreadyInPath()
        {
            string targetDir    = @"C:\Program Files (x86)\Brown and Caldwell\Project Folder Tool\";
            string currentPath  = @"C:\Program Files\dotnet\;C:\Program Files (x86)\Brown and Caldwell\Project Folder Tool\;";
            string expectedPath = @"C:\Program Files\dotnet\;C:\Program Files (x86)\Brown and Caldwell\Project Folder Tool\;";
            string newPath      = AddToPath.addToPath(currentPath, targetDir);

            Assert.AreEqual(expectedPath, newPath);
        }