Unverified Commit 66d3d186 authored by Oleg Alexandrov's avatar Oleg Alexandrov Committed by GitHub
Browse files

Consolidate testing options (#4957)

* Consolidate testing options

* More tuning of testing options, and fix some compiler warnings

* Partial undo, things fail to build
parent f97c727d
Loading
Loading
Loading
Loading
+1 −10
Original line number Original line Diff line number Diff line
@@ -136,10 +136,6 @@ message("\tINSTALL PREFIX: ${CMAKE_INSTALL_PREFIX}")
#===============================================================================
#===============================================================================
#===============================================================================
#===============================================================================


# Set up the ctest tool which is used to run all of the tests.
enable_testing()
include(CTest)

# Set up Anaconda prefix in the case with a non-default conda env is activated
# Set up Anaconda prefix in the case with a non-default conda env is activated
if(EXISTS $ENV{CONDA_PREFIX})
if(EXISTS $ENV{CONDA_PREFIX})
  message("CONDA PREFIX: $ENV{CONDA_PREFIX}")
  message("CONDA PREFIX: $ENV{CONDA_PREFIX}")
@@ -153,10 +149,6 @@ if(JP2KFLAG)
 set(JP2KFLAG 1)
 set(JP2KFLAG 1)
endif()
endif()


# Set up the ctest tool which is used to run all of the tests.
enable_testing()
include(CTest)

# Specify flags used
# Specify flags used
# on linux, add the conda prefix to handle possible issues with rpaths at link time
# on linux, add the conda prefix to handle possible issues with rpaths at link time
# sometimes third parties do not set their rpaths correctly
# sometimes third parties do not set their rpaths correctly
@@ -608,8 +600,7 @@ install(PROGRAMS ${CMAKE_BINARY_DIR}/lib/Camera.plugin DESTINATION ${CMAKE_INSTA
#   the end of this file containing a CMakeLists.txt file which includes all of
#   the end of this file containing a CMakeLists.txt file which includes all of
#   the desired post-install commands inside.
#   the desired post-install commands inside.
add_subdirectory(cmake)
add_subdirectory(cmake)
option (BUILD_TESTS "Build tests" ON)
if(buildTests)
if(BUILD_TESTS)
  include(CTest)
  include(CTest)
  enable_testing()
  enable_testing()
  add_subdirectory(tests)
  add_subdirectory(tests)
+0 −2
Original line number Original line Diff line number Diff line
@@ -133,7 +133,6 @@ namespace Isis {


      TextFile cameraAngle(cameraAngleDefs);
      TextFile cameraAngle(cameraAngleDefs);
      int numLines = cameraAngle.LineCount();
      int numLines = cameraAngle.LineCount();
      bool foundfilter = false;
      for(int i = 0; i < numLines; i++) {
      for(int i = 0; i < numLines; i++) {
        QString line;
        QString line;
        cameraAngle.GetLine(line, true);
        cameraAngle.GetLine(line, true);
@@ -142,7 +141,6 @@ namespace Isis {
        if(tokens.count() > 2 && tokens.first() == filter) {
        if(tokens.count() > 2 && tokens.first() == filter) {
          center = toDouble(tokens[1]);
          center = toDouble(tokens[1]);
          width = toDouble(tokens[2]);
          width = toDouble(tokens[2]);
          foundfilter = true;
          break;
          break;
        }
        }
      }
      }
+1 −1
Original line number Original line Diff line number Diff line
@@ -663,7 +663,7 @@ namespace Isis {
    }
    }
    else {
    else {
      throw IException(IException::Unknown,
      throw IException(IException::Unknown,
                       QObject::tr("No existing files found with a numerial version matching [%1] "
                       QObject::tr("No existing files found with a numerical version matching [%1] "
                                   "in [%2]")
                                   "in [%2]")
                         .arg(FileName(expanded()).name()).arg(path()),
                         .arg(FileName(expanded()).name()).arg(path()),
                       _FILEINFO_);
                       _FILEINFO_);
+2 −2
Original line number Original line Diff line number Diff line
@@ -638,7 +638,7 @@ Testing Numerical-Only Versioning
		New version changed FileName: 1
		New version changed FileName: 1


	Testing Versioning Methods [??tttt]
	Testing Versioning Methods [??tttt]
		Highest Version Name:          		Highest Version Failed:     **ERROR** No existing files found with a numerial version matching [??tttt] in [.].
		Highest Version Name:          		Highest Version Failed:     **ERROR** No existing files found with a numerical version matching [??tttt] in [.].
		New Version Name:              01tttt
		New Version Name:              01tttt
		New Version Orig:              ./01tttt
		New Version Orig:              ./01tttt
		New Version Orig Path:         .
		New Version Orig Path:         .
@@ -655,7 +655,7 @@ Testing Numerical-Only Versioning
		New version changed FileName: 1
		New version changed FileName: 1


	Testing Versioning Methods [junk?]
	Testing Versioning Methods [junk?]
		Highest Version Name:          		Highest Version Failed:     **ERROR** No existing files found with a numerial version matching [junk?] in [.].
		Highest Version Name:          		Highest Version Failed:     **ERROR** No existing files found with a numerical version matching [junk?] in [.].
		New Version Name:              junk1
		New Version Name:              junk1
		New Version Orig:              ./junk1
		New Version Orig:              ./junk1
		New Version Orig Path:         .
		New Version Orig Path:         .
+1 −1
Original line number Original line Diff line number Diff line
@@ -282,7 +282,7 @@ namespace Isis {
  QString fileListToString(QVector<QString> fileList) {
  QString fileListToString(QVector<QString> fileList) {
    QString filesAsString("(");
    QString filesAsString("(");


    for (size_t i = 0; i < fileList.size(); i++) {
    for (int i = 0; i < fileList.size(); i++) {
      FileName file(fileList[i]);
      FileName file(fileList[i]);


      filesAsString += file.expanded();
      filesAsString += file.expanded();