Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(20)

Issue 2561803002: Cronet smoke tests (Closed)

Created:
4 years ago by kapishnikov
Modified:
3 years, 11 months ago
Reviewers:
pauljensen, mef
CC:
chromium-reviews, cbentzel+watch_chromium.org, xunjieli, use bnc(a)chromium.org instead
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Cronet smoke tests 1. Added test support classes that allow running the smoke tests in different environments against different servers. There is one support class for Java-only tests and one that requires H2 & QUIC. The concrete implementation of support classes is determined at runtime by reading the value of |TestSupportImplClass| from the Android string resource file. 2. Added two test APKs one for Java only deployment and one to test behavior when the native “.so” file is absent. 3. Enabled proguarding for the existing unit tests. The new APKS also run proguard in order to check the correctness of proguard configs for different deployments. 4. Added new HttpServer for Java-only scenario that does not depend on Chromium “base” and “net” modules. 5. Added two additional smoke QUIC & H2 tests to the existing test APK. To run all smoke tests, execute: ninja -C out/Debug cronet_smoketests_platform_only_instrumentation_apk \ cronet_smoketests_missing_native_library_instrumentation_apk \ cronet_test_instrumentation_apk -j 240 && \ ./out/Debug/bin/run_cronet_smoketests_platform_only_instrumentation_apk && \ ./out/Debug/bin/run_cronet_smoketests_missing_native_library_instrumentation_apk && \ ./out/Debug/bin/run_cronet_test_instrumentation_apk \ --test-filter=org.chromium.net.smoke.* The output jars that contain the smoke tests: ./out/Debug/lib.java/components/cronet/android/cronet_smoketests_missing_native_library_java.jar ./out/Debug/lib.java/components/cronet/android/cronet_smoketests_native_java.jar ./out/Debug/lib.java/components/cronet/android/cronet_smoketests_platform_only_java.jar BUG=669264 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.android:android_cronet_tester Committed: https://crrev.com/7a4cba9f6d608b3347984e3aaa6f7dfd1d9f63b3 Cr-Commit-Position: refs/heads/master@{#440760}

Patch Set 1 #

Patch Set 2 : Rebase #

Total comments: 16

Patch Set 3 : Addressed Helen's comments #

Patch Set 4 : Renamed ChromiumQuicTestSupport to ChromiumNativeTestSupport #

Total comments: 27

Patch Set 5 : Addressed some of Misha's comments #

Patch Set 6 : Re-implemented TestUrlRequestCallback. Got rid of API(19) requirement. #

Patch Set 7 : Got rid of //base/android/proguard/chromium_apk.flags proguard config. #

Total comments: 41

Patch Set 8 : Addressed Misha's comments #

Patch Set 9 : Changed @Smoke to @SmallTest #

Total comments: 9

Patch Set 10 : Code cleaning #

Patch Set 11 : More cleaning #

Patch Set 12 : Moved to android.support.test.filters & added support for network-security-config #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1081 lines, -8 lines) Patch
M components/cronet/android/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +151 lines, -3 lines 0 comments Download
M components/cronet/android/cronet_impl_common_proguard.cfg View 1 2 3 4 5 6 7 1 chunk +5 lines, -1 line 0 comments Download
M components/cronet/android/cronet_impl_native_proguard.cfg View 1 2 3 4 5 6 1 chunk +4 lines, -0 lines 0 comments Download
D components/cronet/android/test/javaperftests/proguard.cfg View 1 2 3 4 5 6 7 1 chunk +0 lines, -4 lines 0 comments Download
A components/cronet/android/test/proguard.cfg View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +19 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/res/native/values/strings.xml View 1 2 3 4 1 chunk +11 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/res/native/xml/network_security_config.xml View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +9 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/res/platform_only/values/strings.xml View 1 2 3 4 5 6 7 1 chunk +11 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/res/platform_only/xml/network_security_config.xml View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +9 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/ChromiumNativeTestSupport.java View 1 2 3 4 5 6 7 8 9 1 chunk +113 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/ChromiumPlatformOnlyTestSupport.java View 1 2 3 4 5 6 7 8 9 1 chunk +53 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/CronetSmokeTestCase.java View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +90 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/Http2Test.java View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +44 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/HttpTestServer.java View 1 2 3 4 5 6 7 1 chunk +121 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/MissingNativeLibraryTest.java View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +48 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/NativeCronetTestCase.java View 1 2 3 4 5 6 7 1 chunk +55 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/PlatformOnlyEngineTest.java View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +47 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/QuicTest.java View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +72 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/SmokeTestRequestCallback.java View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +126 lines, -0 lines 0 comments Download
A components/cronet/android/test/smoketests/src/org/chromium/net/smoke/TestSupport.java View 1 2 3 4 5 6 7 8 9 10 1 chunk +93 lines, -0 lines 0 comments Download

Messages

Total messages: 32 (17 generated)
kapishnikov
PTAL! If the change is okay, we need to add the new two APKs to ...
4 years ago (2016-12-08 17:53:19 UTC) #4
xunjieli
Thanks for cc-ing me. Code is self-explanatory, and I agree that a doc is not ...
4 years ago (2016-12-08 18:18:30 UTC) #5
kapishnikov
Helen, thanks for the comments! I have addressed them or added an explanation. https://codereview.chromium.org/2561803002/diff/20001/components/cronet/android/test/smoketests/src/org/chromium/net/smoke/BrokenSoFileTest.java File ...
4 years ago (2016-12-08 19:56:16 UTC) #7
mef
Looks reasonable, although quite big. https://codereview.chromium.org/2561803002/diff/60001/components/cronet/android/BUILD.gn File components/cronet/android/BUILD.gn (right): https://codereview.chromium.org/2561803002/diff/60001/components/cronet/android/BUILD.gn#newcode592 components/cronet/android/BUILD.gn:592: java_only_smoke_test_common_srcs = [ naming ...
4 years ago (2016-12-08 23:17:18 UTC) #8
pauljensen
https://codereview.chromium.org/2561803002/diff/60001/components/cronet/android/test/smoketests/src/org/chromium/net/smoke/TestUrlRequestCallback.java File components/cronet/android/test/smoketests/src/org/chromium/net/smoke/TestUrlRequestCallback.java (right): https://codereview.chromium.org/2561803002/diff/60001/components/cronet/android/test/smoketests/src/org/chromium/net/smoke/TestUrlRequestCallback.java#newcode30 components/cronet/android/test/smoketests/src/org/chromium/net/smoke/TestUrlRequestCallback.java:30: class TestUrlRequestCallback extends UrlRequest.Callback { On 2016/12/08 23:17:18, mef ...
4 years ago (2016-12-15 04:15:49 UTC) #9
kapishnikov
https://codereview.chromium.org/2561803002/diff/60001/components/cronet/android/BUILD.gn File components/cronet/android/BUILD.gn (right): https://codereview.chromium.org/2561803002/diff/60001/components/cronet/android/BUILD.gn#newcode592 components/cronet/android/BUILD.gn:592: java_only_smoke_test_common_srcs = [ On 2016/12/08 23:17:18, mef wrote: > ...
4 years ago (2016-12-19 19:31:11 UTC) #11
kapishnikov
Uploaded a new PS. With the patch, all comments should be currently addressed. https://codereview.chromium.org/2561803002/diff/60001/components/cronet/android/BUILD.gn File ...
4 years ago (2016-12-19 23:33:41 UTC) #12
mef
looks reasonable https://codereview.chromium.org/2561803002/diff/120001/components/cronet/android/BUILD.gn File components/cronet/android/BUILD.gn (right): https://codereview.chromium.org/2561803002/diff/120001/components/cronet/android/BUILD.gn#newcode592 components/cronet/android/BUILD.gn:592: cronet_smoketests_java_only_common_srcs = [ nit: maybe s/java_only/platform_only/ here ...
4 years ago (2016-12-20 20:17:46 UTC) #13
kapishnikov
https://codereview.chromium.org/2561803002/diff/120001/components/cronet/android/BUILD.gn File components/cronet/android/BUILD.gn (right): https://codereview.chromium.org/2561803002/diff/120001/components/cronet/android/BUILD.gn#newcode592 components/cronet/android/BUILD.gn:592: cronet_smoketests_java_only_common_srcs = [ On 2016/12/20 20:17:45, mef wrote: > ...
4 years ago (2016-12-22 19:21:13 UTC) #15
mef
lgtm https://codereview.chromium.org/2561803002/diff/120001/components/cronet/android/test/smoketests/src/org/chromium/net/smoke/TestSupport.java File components/cronet/android/test/smoketests/src/org/chromium/net/smoke/TestSupport.java (right): https://codereview.chromium.org/2561803002/diff/120001/components/cronet/android/test/smoketests/src/org/chromium/net/smoke/TestSupport.java#newcode11 components/cronet/android/test/smoketests/src/org/chromium/net/smoke/TestSupport.java:11: import org.chromium.net.ExperimentalCronetEngine; On 2016/12/22 19:21:13, kapishnikov wrote: > ...
4 years ago (2016-12-22 21:35:29 UTC) #16
kapishnikov
https://codereview.chromium.org/2561803002/diff/160001/components/cronet/android/test/smoketests/src/org/chromium/net/smoke/ChromiumNativeTestSupport.java File components/cronet/android/test/smoketests/src/org/chromium/net/smoke/ChromiumNativeTestSupport.java (right): https://codereview.chromium.org/2561803002/diff/160001/components/cronet/android/test/smoketests/src/org/chromium/net/smoke/ChromiumNativeTestSupport.java#newcode36 components/cronet/android/test/smoketests/src/org/chromium/net/smoke/ChromiumNativeTestSupport.java:36: public void addHostResolverRules(JSONObject json) { On 2016/12/22 21:35:29, mef ...
4 years ago (2016-12-22 22:13:31 UTC) #17
mef
lgtm https://codereview.chromium.org/2561803002/diff/160001/components/cronet/android/test/smoketests/src/org/chromium/net/smoke/NativeCronetTestCase.java File components/cronet/android/test/smoketests/src/org/chromium/net/smoke/NativeCronetTestCase.java (right): https://codereview.chromium.org/2561803002/diff/160001/components/cronet/android/test/smoketests/src/org/chromium/net/smoke/NativeCronetTestCase.java#newcode43 components/cronet/android/test/smoketests/src/org/chromium/net/smoke/NativeCronetTestCase.java:43: mCronetEngine.startNetLogToFile( On 2016/12/22 22:13:30, kapishnikov wrote: > On ...
4 years ago (2016-12-22 22:17:06 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2561803002/220001
3 years, 12 months ago (2016-12-27 17:40:36 UTC) #27
commit-bot: I haz the power
Committed patchset #12 (id:220001)
3 years, 12 months ago (2016-12-27 17:45:24 UTC) #30
commit-bot: I haz the power
3 years, 11 months ago (2017-01-02 15:46:22 UTC) #32
Message was sent while issue was closed.
Patchset 12 (id:??) landed as
https://crrev.com/7a4cba9f6d608b3347984e3aaa6f7dfd1d9f63b3
Cr-Commit-Position: refs/heads/master@{#440760}

Powered by Google App Engine
This is Rietveld 408576698