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

Issue 2434563005: [sensors] Add a browser test to sanity check ambient light sensor. (Closed)

Created:
4 years, 2 months ago by darktears
Modified:
4 years, 1 month ago
CC:
chromium-reviews, darin-cc_chromium.org, mac-reviews_chromium.org, Ken Rockot(use gerrit already)
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[sensors] Add a browser test to sanity check ambient light sensor. The idea of the test is to sanity check the entire generic sensor integration especially to verify that the data put in the shared buffer is correctly handled by Blink. The patch add a way to provide a fake provider which will create fake sensors so we have a reliable and hardware independent solution. The rest of the testing is happening either as layout tests or as unittests in device/generic_sensor. BUG=606766 Committed: https://crrev.com/17dc30da8eac6754b74cadf5a530cad8c14c22f8 Cr-Commit-Position: refs/heads/master@{#428025}

Patch Set 1 #

Patch Set 2 : Test timestamp as well #

Patch Set 3 : Move test to content/browser/ and fix Windows+Android build #

Patch Set 4 : Fix Win Clang #

Total comments: 6

Patch Set 5 : Fixes for comments #

Patch Set 6 : Delete Fake Provider #

Patch Set 7 : Nit #

Total comments: 1

Patch Set 8 : static #

Total comments: 1

Patch Set 9 : Fix nits found by Reilly #

Unified diffs Side-by-side diffs Delta from patch set Stats (+259 lines, -48 lines) Patch
A content/browser/generic_sensor_browsertest.cc View 1 2 3 4 5 6 7 1 chunk +136 lines, -0 lines 0 comments Download
M content/test/BUILD.gn View 1 2 3 4 2 chunks +2 lines, -0 lines 0 comments Download
A content/test/data/generic_sensor/ambient_light_sensor_test.html View 1 1 chunk +38 lines, -0 lines 0 comments Download
M device/generic_sensor/BUILD.gn View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M device/generic_sensor/platform_sensor_provider.h View 1 2 3 4 1 chunk +5 lines, -0 lines 0 comments Download
A device/generic_sensor/platform_sensor_provider.cc View 1 2 3 4 5 6 7 8 1 chunk +40 lines, -0 lines 0 comments Download
A device/generic_sensor/platform_sensor_provider_android.h View 1 2 1 chunk +35 lines, -0 lines 0 comments Download
M device/generic_sensor/platform_sensor_provider_android.cc View 1 2 2 chunks +1 line, -25 lines 0 comments Download
D device/generic_sensor/platform_sensor_provider_default.cc View 1 2 1 chunk +0 lines, -14 lines 0 comments Download
M device/generic_sensor/platform_sensor_provider_mac.cc View 1 chunk +0 lines, -5 lines 0 comments Download

Messages

Total messages: 68 (37 generated)
darktears
I'm not sure the location is the appropriate place. I can't put the browser test ...
4 years, 2 months ago (2016-10-19 20:35:58 UTC) #2
Reilly Grant (use Gerrit)
The placement is awkward because this should be a layout test using mocked Mojo services. ...
4 years, 2 months ago (2016-10-19 21:28:23 UTC) #3
darktears
On 2016/10/19 at 21:28:23, reillyg wrote: > The placement is awkward because this should be ...
4 years, 2 months ago (2016-10-19 22:29:22 UTC) #4
Reilly Grant (use Gerrit)
On 2016/10/19 at 22:29:22, alexis.menard wrote: > On 2016/10/19 at 21:28:23, reillyg wrote: > > ...
4 years, 2 months ago (2016-10-20 00:01:27 UTC) #5
Mikhail
On 2016/10/20 00:01:27, Reilly Grant wrote: > On 2016/10/19 at 22:29:22, alexis.menard wrote: > > ...
4 years, 2 months ago (2016-10-20 13:32:16 UTC) #6
darktears
On 2016/10/20 at 13:32:16, mikhail.pozdnyakov wrote: > On 2016/10/20 00:01:27, Reilly Grant wrote: > > ...
4 years, 2 months ago (2016-10-21 16:27:47 UTC) #7
Reilly Grant (use Gerrit)
I talked to rockot@ about this and the conclusion we came to was that there ...
4 years, 2 months ago (2016-10-21 17:32:56 UTC) #8
darktears
On 2016/10/21 at 17:32:56, reillyg wrote: > I talked to rockot@ about this and the ...
4 years, 2 months ago (2016-10-21 20:51:30 UTC) #10
Reilly Grant (use Gerrit)
On 2016/10/21 at 20:51:30, alexis.menard wrote: > On 2016/10/21 at 17:32:56, reillyg wrote: > > ...
4 years, 2 months ago (2016-10-21 21:49:18 UTC) #15
darktears
On 2016/10/21 21:49:18, Reilly Grant wrote: > On 2016/10/21 at 20:51:30, alexis.menard wrote: > > ...
4 years, 2 months ago (2016-10-21 23:36:18 UTC) #20
Reilly Grant (use Gerrit)
https://codereview.chromium.org/2434563005/diff/60001/content/browser/generic_sensor_browsertest.cc File content/browser/generic_sensor_browsertest.cc (right): https://codereview.chromium.org/2434563005/diff/60001/content/browser/generic_sensor_browsertest.cc#newcode42 content/browser/generic_sensor_browsertest.cc:42: (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); base::TimeTicks() is 0 so why not ...
4 years, 2 months ago (2016-10-22 02:31:37 UTC) #23
Mikhail
https://codereview.chromium.org/2434563005/diff/60001/content/browser/generic_sensor_browsertest.cc File content/browser/generic_sensor_browsertest.cc (right): https://codereview.chromium.org/2434563005/diff/60001/content/browser/generic_sensor_browsertest.cc#newcode42 content/browser/generic_sensor_browsertest.cc:42: (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF(); On 2016/10/22 02:31:36, Reilly Grant wrote: ...
4 years, 2 months ago (2016-10-24 06:41:56 UTC) #24
darktears
On 2016/10/22 at 02:31:37, reillyg wrote: > https://codereview.chromium.org/2434563005/diff/60001/content/browser/generic_sensor_browsertest.cc > File content/browser/generic_sensor_browsertest.cc (right): > > https://codereview.chromium.org/2434563005/diff/60001/content/browser/generic_sensor_browsertest.cc#newcode42 ...
4 years, 1 month ago (2016-10-24 20:47:03 UTC) #25
darktears
On 2016/10/24 at 06:41:56, mikhail.pozdnyakov wrote: > https://codereview.chromium.org/2434563005/diff/60001/content/browser/generic_sensor_browsertest.cc > File content/browser/generic_sensor_browsertest.cc (right): > > https://codereview.chromium.org/2434563005/diff/60001/content/browser/generic_sensor_browsertest.cc#newcode42 ...
4 years, 1 month ago (2016-10-24 20:56:12 UTC) #26
Reilly Grant (use Gerrit)
On 2016/10/24 at 20:56:12, alexis.menard wrote: > On 2016/10/24 at 06:41:56, mikhail.pozdnyakov wrote: > > ...
4 years, 1 month ago (2016-10-24 21:24:07 UTC) #31
darktears
On 2016/10/24 at 21:06:53, commit-bot wrote: > Dry run: Try jobs failed on following builders: ...
4 years, 1 month ago (2016-10-24 21:24:18 UTC) #32
darktears
On 2016/10/24 at 21:24:07, reillyg wrote: > On 2016/10/24 at 20:56:12, alexis.menard wrote: > > ...
4 years, 1 month ago (2016-10-25 18:17:59 UTC) #37
darktears
On 2016/10/24 at 21:24:07, reillyg wrote: > On 2016/10/24 at 20:56:12, alexis.menard wrote: > > ...
4 years, 1 month ago (2016-10-26 15:24:40 UTC) #40
Mikhail
https://codereview.chromium.org/2434563005/diff/120001/content/browser/generic_sensor_browsertest.cc File content/browser/generic_sensor_browsertest.cc (right): https://codereview.chromium.org/2434563005/diff/120001/content/browser/generic_sensor_browsertest.cc#newcode114 content/browser/generic_sensor_browsertest.cc:114: device::PlatformSensorProvider::SetProviderForTesting(nullptr); ^ this also should be done on IO ...
4 years, 1 month ago (2016-10-26 17:02:12 UTC) #43
darktears
On 2016/10/26 at 17:34:56, commit-bot wrote: > Dry run: This issue passed the CQ dry ...
4 years, 1 month ago (2016-10-26 18:25:36 UTC) #46
Reilly Grant (use Gerrit)
lgtm https://codereview.chromium.org/2434563005/diff/140001/device/generic_sensor/platform_sensor_provider.cc File device/generic_sensor/platform_sensor_provider.cc (right): https://codereview.chromium.org/2434563005/diff/140001/device/generic_sensor/platform_sensor_provider.cc#newcode16 device/generic_sensor/platform_sensor_provider.cc:16: } nit: clang-format seems to be messing up ...
4 years, 1 month ago (2016-10-26 19:55:26 UTC) #47
darktears
On 2016/10/26 19:55:26, Reilly Grant wrote: > lgtm > > https://codereview.chromium.org/2434563005/diff/140001/device/generic_sensor/platform_sensor_provider.cc > File device/generic_sensor/platform_sensor_provider.cc (right): ...
4 years, 1 month ago (2016-10-26 20:14:58 UTC) #50
jam
On 2016/10/26 20:14:58, darktears wrote: > On 2016/10/26 19:55:26, Reilly Grant wrote: > > lgtm ...
4 years, 1 month ago (2016-10-26 21:09:49 UTC) #53
darktears
On 2016/10/26 at 21:09:49, jam wrote: > On 2016/10/26 20:14:58, darktears wrote: > > On ...
4 years, 1 month ago (2016-10-26 21:20:59 UTC) #56
sky
jam@ is an owner of content, so you don't need me for content/test. I'm removing ...
4 years, 1 month ago (2016-10-26 23:30:07 UTC) #58
jam
On 2016/10/26 21:20:59, darktears wrote: > On 2016/10/26 at 21:09:49, jam wrote: > > On ...
4 years, 1 month ago (2016-10-27 01:15:12 UTC) #59
Mikhail
lgtm
4 years, 1 month ago (2016-10-27 06:01:45 UTC) #60
Paweł Hajdan Jr.
LGTM
4 years, 1 month ago (2016-10-27 08:09:33 UTC) #61
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/2434563005/160001
4 years, 1 month ago (2016-10-27 14:43:48 UTC) #64
commit-bot: I haz the power
Committed patchset #9 (id:160001)
4 years, 1 month ago (2016-10-27 14:47:51 UTC) #66
commit-bot: I haz the power
4 years, 1 month ago (2016-10-27 14:51:13 UTC) #68
Message was sent while issue was closed.
Patchset 9 (id:??) landed as
https://crrev.com/17dc30da8eac6754b74cadf5a530cad8c14c22f8
Cr-Commit-Position: refs/heads/master@{#428025}

Powered by Google App Engine
This is Rietveld 408576698