From 68c577afc2fb33b5e66b820bcc9043fed1071456 Mon Sep 17 00:00:00 2001 From: ajmichael Date: Wed, 6 Dec 2017 08:13:50 -0800 Subject: [PATCH] Fix some broken targets and failing tests. RELNOTES: None PiperOrigin-RevId: 178099410 --- src/test/java/com/google/devtools/build/lib/BUILD | 5 ++++- src/tools/runfiles/runfiles_posix_test.sh | 0 tools/build_defs/pkg/BUILD | 4 ++++ tools/osx/xcode_version_flag.bzl | 2 +- tools/test/BUILD | 1 + .../com/google/devtools/lcovmerger/LcovMergerTest.java | 4 ++-- 6 files changed, 12 insertions(+), 4 deletions(-) mode change 100644 => 100755 src/tools/runfiles/runfiles_posix_test.sh diff --git a/src/test/java/com/google/devtools/build/lib/BUILD b/src/test/java/com/google/devtools/build/lib/BUILD index a34ea882564f95..21c6eb59d97e03 100644 --- a/src/test/java/com/google/devtools/build/lib/BUILD +++ b/src/test/java/com/google/devtools/build/lib/BUILD @@ -1,5 +1,8 @@ package( - default_visibility = ["//src/test/java/com/google/devtools/build/lib:__subpackages__"], + default_visibility = [ + "//src/test/java/com/google/devtools/build/lib:__subpackages__", + "//tools/test:__pkg__", + ], ) # Tests for Windows-specific functionality that can run cross-platform. diff --git a/src/tools/runfiles/runfiles_posix_test.sh b/src/tools/runfiles/runfiles_posix_test.sh old mode 100644 new mode 100755 diff --git a/tools/build_defs/pkg/BUILD b/tools/build_defs/pkg/BUILD index 563eef8ceffde5..2f55d7fd0e9b1c 100644 --- a/tools/build_defs/pkg/BUILD +++ b/tools/build_defs/pkg/BUILD @@ -32,6 +32,8 @@ py_test( ], data = [":archive_testdata"], srcs_version = "PY2AND3", + # archive.py requires xzcat, which is not available by default on Mac + tags = ["noci"], deps = [":archive"], ) @@ -216,6 +218,8 @@ sh_test( ":test-tar-xz.tar.xz", ":titi_test_all.changes", ], + # archive.py requires xzcat, which is not available by default on Mac + tags = ["noci"], deps = [ "//src/test/shell:bashunit", ], diff --git a/tools/osx/xcode_version_flag.bzl b/tools/osx/xcode_version_flag.bzl index 38d52445a6d5ee..4630e6e9e8988d 100644 --- a/tools/osx/xcode_version_flag.bzl +++ b/tools/osx/xcode_version_flag.bzl @@ -81,7 +81,7 @@ def _macos_sdk_version_flag_impl(ctx): return struct(providers = [ config_common.FeatureFlagInfo(value = _strip_version( xcode_config.sdk_version_for_platform( - apple_common.platform.macos_device)))]) + apple_common.platform.macos)))]) xcode_version_flag = rule( diff --git a/tools/test/BUILD b/tools/test/BUILD index 6fc7bbdc948b16..5b9dd5e5af1b92 100644 --- a/tools/test/BUILD +++ b/tools/test/BUILD @@ -24,6 +24,7 @@ java_test( deps = [ ":LcovMergerTestUtils", "//src/main/java/com/google/devtools/build/lib/vfs", + "//src/test/java/com/google/devtools/build/lib:foundations_testutil", "//src/test/java/com/google/devtools/build/lib:testutil", "//third_party:junit4", "//third_party:truth", diff --git a/tools/test/LcovMerger/javatests/com/google/devtools/lcovmerger/LcovMergerTest.java b/tools/test/LcovMerger/javatests/com/google/devtools/lcovmerger/LcovMergerTest.java index f34e374f0a3f58..8460b7eb5c1a92 100644 --- a/tools/test/LcovMerger/javatests/com/google/devtools/lcovmerger/LcovMergerTest.java +++ b/tools/test/LcovMerger/javatests/com/google/devtools/lcovmerger/LcovMergerTest.java @@ -18,7 +18,7 @@ import com.google.devtools.build.lib.testutil.Scratch; import com.google.devtools.build.lib.vfs.FileSystemUtils; -import com.google.devtools.build.lib.vfs.FileSystems; +import com.google.devtools.build.lib.vfs.util.FileSystems; import java.io.File; import java.io.IOException; import java.nio.file.Files; @@ -33,7 +33,7 @@ public class LcovMergerTest { private final Scratch scratch = - new Scratch(FileSystemUtils.getWorkingDirectory(FileSystems.initDefaultAsJavaIo())); + new Scratch(FileSystemUtils.getWorkingDirectory(FileSystems.getJavaIoFileSystem())); @Test public void testZeroDatFile() throws IOException {