set( CTEST_CUSTOM_MAXIMUM_NUMBER_OF_ERRORS 1000 )
set( CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS 1000 )

##------------------------------------------------------------------------------
## Ignore warnings in generated code during the build process
set (CTEST_CUSTOM_WARNING_EXCEPTION
  ${CTEST_CUSTOM_WARNING_EXCEPTION}
  "moab"
  "smtk/SMTKCorePython"
  "ClientServer.cxx:[0-9]*:[0-9]*: warning: use of old-style cast"
  "Python/.* warning: declaration of .* shadows a member of 'this' \\[-Wshadow\\]"
  "vtkPythonArgs.h.* warning: use of old-style cast \\[-Wold-style-cast\\]"
  "Done, 0 warnings"
  # The KWIML*_VERIFY_ symbols are extern but not actually defined anywhere.
  # They are only there to cause compiler errors if one of the determined values
  # is wrong. This confuses shiboken, so we ignore this warning when it comes
  # from shiboken's code generation.
  "WARNING scope not found for symbol:KWIML"
  # This is to squash an "unused parameter" warning in moab.
  "VALGRIND_MAKE_VEC_UNDEFINED"
  # This is to silence shiboken-related warnings involving vtk.
  "WARNING scope not found for function definition:vtkBuffer<ScalarT>"
  # Shiboken doesn't know std::array.
  "WARNING scope not found for function definition:std::array<double>"
)

##------------------------------------------------------------------------------
## Regular expression for error exceptions during build process
#set (CTEST_CUSTOM_ERROR_EXCEPTION
#  ${CTEST_CUSTOM_ERROR_EXCEPTION}
#)

cmake_policy(SET CMP0012 NEW)

if(@SMTK_COVERAGE_ENABLED@)
  set(COVERAGE_EXTRA_FLAGS "-l -p")
  set(CTEST_CUSTOM_COVERAGE_EXCLUDE
    "thirdparty"
    "testing"
    "pybind11"
    "qt"
    )
endif()
