aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rwxr-xr-xsrc/test/shell/bazel/cpp_darwin_integration_test.sh5
-rwxr-xr-xsrc/test/shell/testenv.sh6
2 files changed, 10 insertions, 1 deletions
diff --git a/src/test/shell/bazel/cpp_darwin_integration_test.sh b/src/test/shell/bazel/cpp_darwin_integration_test.sh
index 08cf924f0f..d191ef83b8 100755
--- a/src/test/shell/bazel/cpp_darwin_integration_test.sh
+++ b/src/test/shell/bazel/cpp_darwin_integration_test.sh
@@ -21,6 +21,11 @@ CURRENT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
source "${CURRENT_DIR}/../integration_test_setup.sh" \
|| { echo "integration_test_setup.sh not found!" >&2; exit 1; }
+if ! is_darwin; then
+ echo "This test suite requires running on Darwin. But now is ${PLATFORM}" >&2
+ exit 0
+fi
+
function test_osx_cc_wrapper_rpaths_handling() {
mkdir -p cpp/rpaths
cat > cpp/rpaths/BUILD <<EOF
diff --git a/src/test/shell/testenv.sh b/src/test/shell/testenv.sh
index 6b31494f4b..e9eee3355d 100755
--- a/src/test/shell/testenv.sh
+++ b/src/test/shell/testenv.sh
@@ -19,13 +19,17 @@
# TODO(bazel-team): This file is currently an append of the old testenv.sh and
# test-setup.sh files. This must be cleaned up eventually.
-# Windows
PLATFORM="$(uname -s | tr 'A-Z' 'a-z')"
+
function is_windows() {
# On windows, the shell test is actually running on msys
[[ "${PLATFORM}" =~ msys_nt* ]]
}
+function is_darwin() {
+ [[ "${PLATFORM}" =~ darwin ]]
+}
+
function _log_base() {
prefix=$1
shift