Backported: https://github.com/Kitware/CMake/commit/79ce0f434e916684d734e136b92e14f472a9d14a diff -ur a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt --- a/Tests/CMakeLists.txt 2022-11-01 08:36:33.000000000 -0500 +++ b/Tests/CMakeLists.txt 2023-02-28 15:24:14.294747915 -0600 @@ -1586,6 +1586,7 @@ ) list(APPEND TEST_BUILD_DIRS "${CMake_BINARY_DIR}/Tests/ExternalProject") set_tests_properties(ExternalProject PROPERTIES + ENVIRONMENT GIT_ALLOW_PROTOCOL=file RUN_SERIAL 1 TIMEOUT ${CMAKE_LONG_TEST_TIMEOUT}) @@ -2678,6 +2679,7 @@ -P "${CMake_BINARY_DIR}/Tests/CTestUpdateGIT.cmake" ) list(APPEND TEST_BUILD_DIRS "${CMake_BINARY_DIR}/Tests/${CTestUpdateGIT_DIR}") + set_property(TEST CTest.UpdateGIT PROPERTY ENVIRONMENT GIT_ALLOW_PROTOCOL=file) endif() # Test CTest Update with HG