public void ShouldCheckoutInsteadOfUpdateIfCVSFoldersDoNotExist() { var lastDirectorySeparatorIndex = DefaultWorkingDirectory.TrimEnd().TrimEnd(Path.DirectorySeparatorChar).LastIndexOf(Path.DirectorySeparatorChar); var checkoutWd = DefaultWorkingDirectory.Substring(0, lastDirectorySeparatorIndex); var checkoutDir = DefaultWorkingDirectory.Substring(lastDirectorySeparatorIndex).Trim(Path.DirectorySeparatorChar); ExpectToExecuteArguments( string.Format( @"-d :pserver:[email protected]:/cvsroot/ccnet -q checkout -R -P -d {0} ccnet", StringUtil.AutoDoubleQuoteString(checkoutDir)), checkoutWd); ExpectCvsDirectoryExists(false); cvs.CvsRoot = ":pserver:[email protected]:/cvsroot/ccnet"; cvs.Module = "ccnet"; cvs.AutoGetSource = true; cvs.WorkingDirectory = DefaultWorkingDirectory; cvs.GetSource(IntegrationResult()); }