<commit_before>ADD_EXECUTABLE(SocketServer SocketServer.cxx)
ADD_EXECUTABLE(SocketClient SocketClient.cxx)

IF (VTK_HAS_THREADS OR VTK_USE_MPI)
  IF (VTK_USE_HYBRID)
    ADD_EXECUTABLE(ParallelIsoTest ParallelIso.cxx)
    TARGET_LINK_LIBRARIES(ParallelIsoTest vtkParallel vtkHybrid)
  ENDIF (VTK_USE_HYBRID)

 ADD_EXECUTABLE(GenericCommunicator GenericCommunicator.cxx)
 TARGET_LINK_LIBRARIES(GenericCommunicator vtkParallel)

 ADD_EXECUTABLE(TestPStream TestPStream.cxx)
 TARGET_LINK_LIBRARIES(TestPStream vtkParallel)
ENDIF (VTK_HAS_THREADS OR VTK_USE_MPI)

IF (VTK_HAS_THREADS)
 ADD_EXECUTABLE(ThreadedCommunicator ThreadedCommunicator.cxx)
 TARGET_LINK_LIBRARIES(ThreadedCommunicator vtkParallel)
ENDIF (VTK_HAS_THREADS)

TARGET_LINK_LIBRARIES(SocketServer vtkParallel)
TARGET_LINK_LIBRARIES(SocketClient vtkParallel)

IF (VTK_USE_MPI)
  ADD_EXECUTABLE(MPIGroups MPIGroups.cxx)
  TARGET_LINK_LIBRARIES(MPIGroups vtkParallel)
ENDIF (VTK_USE_MPI)

#
# Add tests, with the data
#

IF (VTK_DATA_ROOT)
  IF (VTK_USE_HYBRID)
    IF (VTK_HAS_THREADS)
      ADD_TEST(ThreadedCommunicator-image 
               ${CXX_TEST_PATH}/ThreadedCommunicator
               -D ${VTK_DATA_ROOT}
               -T ${VTK_BINARY_DIR}/Testing/Temporary
               -V Baseline/Parallel/ThreadedCommunicator.cxx.png)
    ENDIF (VTK_HAS_THREADS)

    IF (VTK_USE_MPI)
     IF (UNIX)
      IF (VTK_MPIRUN_EXE)
        IF(VTK_MPI_MAX_NUMPROCS GREATER 1)
          ADD_TEST(ParallelIsoMPI-image 
            ${VTK_MPIRUN_EXE} ${VTK_MPI_NUMPROC_FLAG} 2 ${VTK_MPI_PREFLAGS} 
                   ${CXX_TEST_PATH}/ParallelIsoTest
                   -D ${VTK_DATA_ROOT}
                   -T ${VTK_BINARY_DIR}/Testing/Temporary
                   -V Baseline/Parallel/ParallelIso.cxx.png
                   ${VTK_MPI_POSTFLAGS})
          ADD_TEST(TestCommunicatorMPI-image 
            ${VTK_MPIRUN_EXE} ${VTK_MPI_NUMPROC_FLAG} 2 ${VTK_MPI_PREFLAGS} 
                   ${CXX_TEST_PATH}/GenericCommunicator
                   -D ${VTK_DATA_ROOT}
                   -T ${VTK_BINARY_DIR}/Testing/Temporary
                   -V Baseline/Parallel/GenericCommunicator.cxx.png
                   ${VTK_MPI_POSTFLAGS})
          ADD_TEST(TestPStreamMPI-image 
            ${VTK_MPIRUN_EXE} ${VTK_MPI_NUMPROC_FLAG} 2 ${VTK_MPI_PREFLAGS} 
                   ${CXX_TEST_PATH}/TestPStream
                   -D ${VTK_DATA_ROOT}
                   -T ${VTK_BINARY_DIR}/Testing/Temporary
                   -V Baseline/Parallel/TestPStream.cxx.png
                   ${VTK_MPI_POSTFLAGS})
        ENDIF(VTK_MPI_MAX_NUMPROCS GREATER 1)
        IF (VTK_MPI_MAX_NUMPROCS)
          IF (VTK_MPI_MAX_NUMPROCS GREATER 3)
           ADD_TEST(MPIGroups-image 
          ${VTK_MPIRUN_EXE} ${VTK_MPI_NUMPROC_FLAG} ${VTK_MPI_MAX_NUMPROCS} ${VTK_MPI_PREFLAGS} 
                   ${CXX_TEST_PATH}/MPIGroups
                   -D ${VTK_DATA_ROOT}
                   -T ${VTK_BINARY_DIR}/Testing/Temporary
                   -V Baseline/Parallel/MPIGroups.cxx.png
                   ${VTK_MPI_POSTFLAGS})
          ENDIF (VTK_MPI_MAX_NUMPROCS GREATER 3)
        ENDIF (VTK_MPI_MAX_NUMPROCS)
      ENDIF(VTK_MPIRUN_EXE)
     ENDIF (UNIX)
    ELSE (VTK_USE_MPI)
      IF (VTK_HAS_THREADS AND VTK_USE_DISPLAY)
        ADD_TEST(ParallelIso-image ${CXX_TEST_PATH}/ParallelIsoTest
                 -D ${VTK_DATA_ROOT}
                 -T ${VTK_BINARY_DIR}/Testing/Temporary
                 -V Baseline/Parallel/ParallelIso.cxx.png)
        ADD_TEST(TestCommunicator-image ${CXX_TEST_PATH}/GenericCommunicator
                 -D ${VTK_DATA_ROOT}
                 -T ${VTK_BINARY_DIR}/Testing/Temporary
                 -V Baseline/Parallel/GenericCommunicator.cxx.png)
      ENDIF (VTK_HAS_THREADS AND VTK_USE_DISPLAY)
    ENDIF (VTK_USE_MPI)
  ENDIF (VTK_USE_HYBRID)
#
# If we do not have the data, still run the tests that we can
#
ELSE (VTK_DATA_ROOT)
  IF (VTK_USE_HYBRID)
    IF (VTK_HAS_THREADS AND VTK_USE_DISPLAY)<commit_msg>Add DistributedData test.<commit_after>ADD_EXECUTABLE(SocketServer SocketServer.cxx)
ADD_EXECUTABLE(SocketClient SocketClient.cxx)

IF (VTK_HAS_THREADS OR VTK_USE_MPI)
  IF (VTK_USE_HYBRID)
    ADD_EXECUTABLE(ParallelIsoTest ParallelIso.cxx)
    TARGET_LINK_LIBRARIES(ParallelIsoTest vtkParallel vtkHybrid)
  ENDIF (VTK_USE_HYBRID)

 ADD_EXECUTABLE(GenericCommunicator GenericCommunicator.cxx)
 TARGET_LINK_LIBRARIES(GenericCommunicator vtkParallel)

 ADD_EXECUTABLE(TestPStream TestPStream.cxx)
 TARGET_LINK_LIBRARIES(TestPStream vtkParallel)
ENDIF (VTK_HAS_THREADS OR VTK_USE_MPI)

IF (VTK_HAS_THREADS)
 ADD_EXECUTABLE(ThreadedCommunicator ThreadedCommunicator.cxx)
 TARGET_LINK_LIBRARIES(ThreadedCommunicator vtkParallel)
ENDIF (VTK_HAS_THREADS)

TARGET_LINK_LIBRARIES(SocketServer vtkParallel)
TARGET_LINK_LIBRARIES(SocketClient vtkParallel)

IF (VTK_USE_MPI)
  ADD_EXECUTABLE(MPIGroups MPIGroups.cxx)
  TARGET_LINK_LIBRARIES(MPIGroups vtkParallel)

  ADD_EXECUTABLE(DistributedData DistributedData.cxx)
  TARGET_LINK_LIBRARIES(DistributedData vtkParallel)
ENDIF (VTK_USE_MPI)

#
# Add tests, with the data
#

IF (VTK_DATA_ROOT)
  IF (VTK_USE_HYBRID)
    IF (VTK_HAS_THREADS)
      ADD_TEST(ThreadedCommunicator-image 
               ${CXX_TEST_PATH}/ThreadedCommunicator
               -D ${VTK_DATA_ROOT}
               -T ${VTK_BINARY_DIR}/Testing/Temporary
               -V Baseline/Parallel/ThreadedCommunicator.cxx.png)
    ENDIF (VTK_HAS_THREADS)

    IF (VTK_USE_MPI)
     IF (UNIX)
      IF (VTK_MPIRUN_EXE)
        IF(VTK_MPI_MAX_NUMPROCS GREATER 1)
          ADD_TEST(ParallelIsoMPI-image 
            ${VTK_MPIRUN_EXE} ${VTK_MPI_NUMPROC_FLAG} 2 ${VTK_MPI_PREFLAGS} 
                   ${CXX_TEST_PATH}/ParallelIsoTest
                   -D ${VTK_DATA_ROOT}
                   -T ${VTK_BINARY_DIR}/Testing/Temporary
                   -V Baseline/Parallel/ParallelIso.cxx.png
                   ${VTK_MPI_POSTFLAGS})
          ADD_TEST(TestCommunicatorMPI-image 
            ${VTK_MPIRUN_EXE} ${VTK_MPI_NUMPROC_FLAG} 2 ${VTK_MPI_PREFLAGS} 
                   ${CXX_TEST_PATH}/GenericCommunicator
                   -D ${VTK_DATA_ROOT}
                   -T ${VTK_BINARY_DIR}/Testing/Temporary
                   -V Baseline/Parallel/GenericCommunicator.cxx.png
                   ${VTK_MPI_POSTFLAGS})
          ADD_TEST(TestPStreamMPI-image 
            ${VTK_MPIRUN_EXE} ${VTK_MPI_NUMPROC_FLAG} 2 ${VTK_MPI_PREFLAGS} 
                   ${CXX_TEST_PATH}/TestPStream
                   -D ${VTK_DATA_ROOT}
                   -T ${VTK_BINARY_DIR}/Testing/Temporary
                   -V Baseline/Parallel/TestPStream.cxx.png
                   ${VTK_MPI_POSTFLAGS})
        ENDIF(VTK_MPI_MAX_NUMPROCS GREATER 1)
        IF (VTK_MPI_MAX_NUMPROCS)
          IF (VTK_MPI_MAX_NUMPROCS GREATER 3)
           ADD_TEST(MPIGroups-image 
          ${VTK_MPIRUN_EXE} ${VTK_MPI_NUMPROC_FLAG} ${VTK_MPI_MAX_NUMPROCS} ${VTK_MPI_PREFLAGS} 
                   ${CXX_TEST_PATH}/MPIGroups
                   -D ${VTK_DATA_ROOT}
                   -T ${VTK_BINARY_DIR}/Testing/Temporary
                   -V Baseline/Parallel/MPIGroups.cxx.png
                   ${VTK_MPI_POSTFLAGS})
          ENDIF (VTK_MPI_MAX_NUMPROCS GREATER 3)
        ENDIF (VTK_MPI_MAX_NUMPROCS)
      ENDIF(VTK_MPIRUN_EXE)
     ENDIF (UNIX)
    ELSE (VTK_USE_MPI)
      IF (VTK_HAS_THREADS AND VTK_USE_DISPLAY)
        ADD_TEST(ParallelIso-image ${CXX_TEST_PATH}/ParallelIsoTest
                 -D ${VTK_DATA_ROOT}
                 -T ${VTK_BINARY_DIR}/Testing/Temporary
                 -V Baseline/Parallel/ParallelIso.cxx.png)
        ADD_TEST(TestCommunicator-image ${CXX_TEST_PATH}/GenericCommunicator
                 -D ${VTK_DATA_ROOT}
                 -T ${VTK_BINARY_DIR}/Testing/Temporary
                 -V Baseline/Parallel/GenericCommunicator.cxx.png)
      ENDIF (VTK_HAS_THREADS AND VTK_USE_DISPLAY)
    ENDIF (VTK_USE_MPI)
  ENDIF (VTK_USE_HYBRID)

  IF (VTK_USE_MPI)
    IF (VTK_MPIRUN_EXE)
      IF(VTK_MPI_MAX_NUMPROCS GREATER 3)
        ADD_TEST(DistributedData-image
          ${VTK_MPIRUN_EXE} ${VTK_MPI_NUMPROC_FLAG} 4 ${VTK_MPI_PREFLAGS}
                 ${CXX_TEST_PATH}/DistributedData
                 -D ${VTK_DATA_ROOT}
                 -T ${VTK_BINARY_DIR}/Testing/Temporary
                 -V Baseline/Parallel/DistributedData.cxx.png
                 ${VTK_MPI_POSTFLAGS})
      ENDIF(VTK_MPI_MAX_NUMPROCS GREATER 3)
    ENDIF (VTK_MPIRUN_EXE)
  ENDIF (VTK_USE_MPI)

#
# If we do not have the data, still run the tests that we can
#
ELSE (VTK_DATA_ROOT)
  IF (VTK_USE_HYBRID)
    IF (VTK_HAS_THREADS AND VTK_USE_DISPLAY)
{'fraction_non_alphanumeric': 0.07878224494538694, 'fraction_numerical': 0.0019753660237043923, 'mean_word_length': 2.624, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3292488', 'n_tokens_mistral': 3360, 'n_tokens_neox': 3168, 'n_words': 434}