Skip to content

Commit 3f94f19

Browse files
authored
Firestore improve cmake file error message (#1140)
* Improve Error Message * Make this change available in other CMakeLists.txt files
1 parent 33709f5 commit 3f94f19

File tree

15 files changed

+165
-15
lines changed

15 files changed

+165
-15
lines changed

admob/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

analytics/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

app/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

app_check/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

auth/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

database/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

dynamic_links/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

firestore/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

firestore/integration_test_internal/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

functions/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

gma/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

installations/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

messaging/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

remote_config/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

storage/integration_test/CMakeLists.txt

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,17 @@ endif()
4242
if(NOT ANDROID)
4343
if (EXISTS ${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py)
4444
# If this is running from inside the SDK directory, run the setup script.
45-
execute_process(COMMAND ${FIREBASE_PYTHON_EXECUTABLE} "${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py" "${CMAKE_CURRENT_LIST_DIR}")
45+
execute_process(
46+
COMMAND
47+
${FIREBASE_PYTHON_EXECUTABLE}
48+
"${CMAKE_CURRENT_LIST_DIR}/../../setup_integration_tests.py"
49+
"${CMAKE_CURRENT_LIST_DIR}"
50+
RESULT_VARIABLE
51+
FIREBASE_PYTHON_EXECUTABLE_RESULT
52+
)
53+
if(NOT FIREBASE_PYTHON_EXECUTABLE_RESULT EQUAL 0)
54+
message(FATAL_ERROR "Failed to run setup_integration_tests.py")
55+
endif()
4656
endif()
4757
endif()
4858

0 commit comments

Comments
 (0)