diff options
author | Brad King <brad.king@kitware.com> | 2009-02-24 15:39:55 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2009-02-24 15:39:55 (GMT) |
commit | 6bdc2b5d99313ab6418b07ff91320135907ac261 (patch) | |
tree | bf6c9386a7987ac5147e7d37a3d0372468dc24ac /Source/CTest/cmCTestUpdateHandler.cxx | |
parent | 1b8ea27bd10c9ac94d190a3eb9be5fa0c955b453 (diff) | |
download | CMake-6bdc2b5d99313ab6418b07ff91320135907ac261.zip CMake-6bdc2b5d99313ab6418b07ff91320135907ac261.tar.gz CMake-6bdc2b5d99313ab6418b07ff91320135907ac261.tar.bz2 |
ENH: Add cmCTestCVS and cmCTestSVN
These cmCTestVC subclasses will implement interaction with CVS and SVN
tools.
Diffstat (limited to 'Source/CTest/cmCTestUpdateHandler.cxx')
-rw-r--r-- | Source/CTest/cmCTestUpdateHandler.cxx | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Source/CTest/cmCTestUpdateHandler.cxx b/Source/CTest/cmCTestUpdateHandler.cxx index 014e16d..cce8f2f 100644 --- a/Source/CTest/cmCTestUpdateHandler.cxx +++ b/Source/CTest/cmCTestUpdateHandler.cxx @@ -27,6 +27,12 @@ #include "cmXMLParser.h" #include "cmXMLSafe.h" +#include "cmCTestVC.h" +#include "cmCTestCVS.h" +#include "cmCTestSVN.h" + +#include <cmsys/auto_ptr.hxx> + //#include <cmsys/RegularExpression.hxx> #include <cmsys/Process.h> @@ -323,6 +329,17 @@ int cmCTestUpdateHandler::ProcessHandler() << " repository type" << std::endl;); + // Create an object to interact with the VCS tool. + cmsys::auto_ptr<cmCTestVC> vc; + switch (this->UpdateType) + { + case e_CVS: vc.reset(new cmCTestCVS(this->CTest, ofs)); break; + case e_SVN: vc.reset(new cmCTestSVN(this->CTest, ofs)); break; + default: vc.reset(new cmCTestVC(this->CTest, ofs)); break; + } + vc->SetCommandLineTool(this->UpdateCommand); + vc->SetSourceDirectory(sourceDirectory); + // And update options std::string updateOptions = this->CTest->GetCTestConfiguration("UpdateOptions"); |