Reland of Fix android_junit_tests and add a GN target for them. (patchset #1 id:1 of https://codereview.webrtc.org/2345163003/ )
Reason for revert:
Bring back the include I managed to accidentally remove.
Original issue's description:
> Revert of Fix android_junit_tests and add a GN target for them. (patchset #3 id:90001 of https://codereview.webrtc.org/2344133002/ )
>
> Reason for revert:
> Breaks bots.
>
> Original issue's description:
> > Reland of Fix android_junit_tests and add a GN target for them. (patchset #1 id:1 of https://codereview.webrtc.org/2341213003/ )
> >
> > Reason for revert:
> > Fix the issue.
> >
> > Original issue's description:
> > > Revert of Fix android_junit_tests and add a GN target for them. (patchset #1 id:20001 of https://codereview.webrtc.org/2346793002/ )
> > >
> > > Reason for revert:
> > > Breaks WebRTC in Chrome on Android:
> > >
> > > https://build.chromium.org/p/chromium.webrtc.fyi/waterfall?builder=Android%20Builder%20(dbg)
> > >
> > > Original issue's description:
> > > > Fix android_junit_tests and add a GN target for them.
> > > >
> > > > BUG=webrtc:6365
> > > > NOTRY=True
> > > >
> > > > Committed: https://crrev.com/bb716daea73889517f996aa29f867563ed63d58a
> > > > Cr-Commit-Position: refs/heads/master@{#14241}
> > >
> > > TBR=magjed@webrtc.org,kjellander@webrtc.org,sakal@webrtc.org
> > > # Skipping CQ checks because original CL landed less than 1 days ago.
> > > NOPRESUBMIT=true
> > > NOTREECHECKS=true
> > > NOTRY=true
> > > BUG=webrtc:6365
> > >
> > > Committed: https://crrev.com/9adb1ff9439aecf4e8ac3972a631bb74df2b6868
> > > Cr-Commit-Position: refs/heads/master@{#14253}
> >
> > TBR=magjed@webrtc.org,kjellander@webrtc.org,henrika@webrtc.org
> > # Skipping CQ checks because original CL landed less than 1 days ago.
> > NOPRESUBMIT=true
> > NOTREECHECKS=true
> > NOTRY=true
> > BUG=webrtc:6365
> >
> > Committed: https://crrev.com/51fe1d805d19bf7c79aad46049d040fae1ae6953
> > Cr-Commit-Position: refs/heads/master@{#14254}
>
> TBR=magjed@webrtc.org,kjellander@webrtc.org,henrika@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:6365
>
> Committed: https://crrev.com/1431d49ea073d88b65303ab843545678fbb6e9f9
> Cr-Commit-Position: refs/heads/master@{#14255}
TBR=magjed@webrtc.org,kjellander@webrtc.org,henrika@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:6365
Review-Url: https://codereview.webrtc.org/2348663003
Cr-Commit-Position: refs/heads/master@{#14264}
diff --git a/webrtc/BUILD.gn b/webrtc/BUILD.gn
index 88c4e09..5b5ed16 100644
--- a/webrtc/BUILD.gn
+++ b/webrtc/BUILD.gn
@@ -12,6 +12,10 @@
import("//build/config/sanitizers/sanitizers.gni")
import("build/webrtc.gni")
import("//third_party/protobuf/proto_library.gni")
+if (is_android) {
+ import("//build/config/android/config.gni")
+ import("//build/config/android/rules.gni")
+}
# Contains the defines and includes in common.gypi that are duplicated both as
# target_defaults and direct_dependent_settings.
@@ -827,4 +831,15 @@
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
+
+ if (is_android) {
+ junit_binary("android_junit_tests") {
+ java_files = [ "androidjunit/src/org/webrtc/CameraEnumerationTest.java" ]
+
+ deps = [
+ "//webrtc/api:libjingle_peerconnection_java",
+ "//webrtc/api:libjingle_peerconnection_jni",
+ ]
+ }
+ }
}