-
Notifications
You must be signed in to change notification settings - Fork 215
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update to latest bazel, rules #189
base: main
Are you sure you want to change the base?
Conversation
@chiragramani I've never used Bazel outside of our Uber context — do you know why this target can't use this import? It may have worked in the past with our old rules and bazel version. I also found this:
|
@alanzeino Thanks for putting up this PR, we'd love the new rules being supported as well where I work. I found that the following diff on the diff --git a/BUILD.bazel b/BUILD.bazel
index 4d276f7..da15ca6 100644
--- a/BUILD.bazel
+++ b/BUILD.bazel
@@ -11,6 +11,9 @@ objc_library(
defines = [
"SWIFT_PACKAGE"
],
+ includes = [
+ "src/iOSSnapshotTestCaseCore/Public"
+ ],
copts = [
"-Wno-deprecated-declarations"
],
@@ -25,5 +28,6 @@ swift_library(
deps = [
":iOSSnapshotTestCaseCore"
],
+ testonly = True,
visibility = ["//visibility:public"]
)
diff --git a/src/iOSSnapshotTestCaseTests/BUILD.bazel b/src/iOSSnapshotTestCaseTests/BUILD.bazel
index 0c63a59..6b59b7b 100644
--- a/src/iOSSnapshotTestCaseTests/BUILD.bazel
+++ b/src/iOSSnapshotTestCaseTests/BUILD.bazel
@@ -7,9 +7,6 @@ objc_library(
deps = [
"//:iOSSnapshotTestCaseCore"
],
- defines = [
- "BAZEL"
- ],
data = glob(["Resources/*.png"], allow_empty = False),
sdk_frameworks = [
"CoreGraphics",
diff --git a/src/iOSSnapshotTestCaseTests/FBSnapshotControllerTests.m b/src/iOSSnapshotTestCaseTests/FBSnapshotControllerTests.m
index 9331038..999a23b 100644
--- a/src/iOSSnapshotTestCaseTests/FBSnapshotControllerTests.m
+++ b/src/iOSSnapshotTestCaseTests/FBSnapshotControllerTests.m
@@ -8,14 +8,8 @@
*/
#import <XCTest/XCTest.h>
-#if BAZEL
-@import iOSSnapshotTestCaseCore;
-@import UIKit;
-@import CoreGraphics;
-@import QuartzCore;
-#else
+
#import "FBSnapshotTestCase.h"
-#endif
@interface FBSnapshotControllerTests : XCTestCase
|
Attempting to update the repo so that the
build.sh
script that is run in the GitHub Action succeeds.