mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-10-05 01:49:02 +00:00
Merge topic 'fix-uploading-vtkm-perf-test' into release-2.1
31b8b2faf ci: fix perftest uploading Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Kenneth Moreland <morelandkd@ornl.gov> Merge-request: !3228
This commit is contained in:
commit
6eae30063a
@ -76,14 +76,6 @@ function(add_benchmark_test benchmark)
|
|||||||
set(VTKm_PERF_COMPARE_JSON "${CMAKE_BINARY_DIR}/$ENV{CI_COMMIT_SHA}_${VTKm_PERF_NAME}.json")
|
set(VTKm_PERF_COMPARE_JSON "${CMAKE_BINARY_DIR}/$ENV{CI_COMMIT_SHA}_${VTKm_PERF_NAME}.json")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Only upload when we are inside a CI build and in master. We need to check
|
|
||||||
# if VTKM_BENCH_RECORDS_TOKEN is either defined or non-empty, the reason is
|
|
||||||
# that in Gitlab CI Variables for protected branches are also defined in MR
|
|
||||||
# from forks, however, they are empty.
|
|
||||||
if (DEFINED ENV{VTKM_BENCH_RECORDS_TOKEN} AND ENV{VTKM_BENCH_RECORDS_TOKEN})
|
|
||||||
set(enable_upload TRUE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set(test_name "PerformanceTest${VTKm_PERF_NAME}")
|
set(test_name "PerformanceTest${VTKm_PERF_NAME}")
|
||||||
|
|
||||||
###TEST INVOKATIONS##########################################################
|
###TEST INVOKATIONS##########################################################
|
||||||
@ -125,7 +117,12 @@ function(add_benchmark_test benchmark)
|
|||||||
-P "${VTKm_SOURCE_DIR}/CMake/testing/VTKmPerformanceTestReport.cmake"
|
-P "${VTKm_SOURCE_DIR}/CMake/testing/VTKmPerformanceTestReport.cmake"
|
||||||
)
|
)
|
||||||
|
|
||||||
if (enable_upload)
|
|
||||||
|
# Only upload when we are inside a CI build and in master. We need to check
|
||||||
|
# if VTKM_BENCH_RECORDS_TOKEN is non-empty, the reason is that in Gitlab CI
|
||||||
|
# Variables for protected branches are also defined in MR from forks,
|
||||||
|
# however, they are empty.
|
||||||
|
if ($ENV{VTKM_BENCH_RECORDS_TOKEN})
|
||||||
add_test(NAME "${test_name}Upload"
|
add_test(NAME "${test_name}Upload"
|
||||||
COMMAND ${CMAKE_COMMAND}
|
COMMAND ${CMAKE_COMMAND}
|
||||||
"-DVTKm_PERF_REPO=${VTKm_PERF_REPO}"
|
"-DVTKm_PERF_REPO=${VTKm_PERF_REPO}"
|
||||||
|
Loading…
Reference in New Issue
Block a user