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

Issue 12967016: Improve <adview> implementation and add tests. (Closed)

Created:
7 years, 9 months ago by rpaquay
Modified:
7 years, 8 months ago
CC:
chromium-reviews, cbentzel+watch_chromium.org, jam, joi+watch-content_chromium.org, Aaron Boodman, darin-cc_chromium.org, chromium-apps-reviews_chromium.org, asargent_no_longer_on_chrome
Base URL:
https://git.chromium.org/chromium/src.git@master
Visibility:
Public.

Description

Improve <adview> implementation and add tests. The first CL for bug 180618 contained initial support for the <adview> tag. This is a follow up CL to * fix issues related to various combinations of flags, permissions and property/attributes behavior, * add corresponding tests, * and improve code readability of "ad_view.js" BUG=226125 TBR=asargent@chromium.org (for trivial changes in chrome/browser/component_updater/test/component_updater_service_unittest.cc) Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=196036

Patch Set 1 #

Patch Set 2 : Fixing test. #

Patch Set 3 : Fix tests. #

Patch Set 4 : Fix comment. #

Total comments: 15

Patch Set 5 : Code review feedback. #

Patch Set 6 : Code review feedback. #

Total comments: 1

Patch Set 7 : Code review feedback. #

Total comments: 56

Patch Set 8 : Code review feedback. #

Patch Set 9 : Code review feedback. #

Patch Set 10 : Code review feedback. #

Patch Set 11 : Code review feedback. #

Total comments: 2

Patch Set 12 : Code review feedback. #

Patch Set 13 : Rebasing. #

Patch Set 14 : Fix build failure due to merge conflict. #

Patch Set 15 : Disable test with dependency on binary file. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1018 lines, -639 lines) Patch
M chrome/browser/component_updater/test/component_updater_service_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 6 chunks +6 lines, -6 lines 0 comments Download
M chrome/browser/extensions/ad_view_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +127 lines, -16 lines 0 comments Download
M chrome/browser/extensions/api/management/management_browsertest.cc View 5 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/extensions/extension_disabled_ui_browsertest.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/renderer/resources/extensions/ad_view.js View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +298 lines, -129 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network/ads/image315.png View 0 chunks +-1 lines, --1 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network/ads/image316.png View 0 chunks +-1 lines, --1 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network/ads/image317.png View 0 chunks +-1 lines, --1 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network/ads/image318.png View 0 chunks +-1 lines, --1 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network/ads/image319.png View 0 chunks +-1 lines, --1 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network/testsdk.html View 1 chunk +0 lines, -24 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network/testsdk.js View 1 chunk +0 lines, -134 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network_loaded/chrometest.js View 1 chunk +0 lines, -25 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network_loaded/displayad.js View 1 chunk +0 lines, -100 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network_loaded/index.html View 1 chunk +0 lines, -27 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network_loaded/main.js View 1 chunk +0 lines, -14 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/ad_network_loaded/manifest.json View 1 chunk +0 lines, -14 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/ad_network_site/ads/image315.png View 1 0 chunks +-1 lines, --1 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/ad_network_site/testsdk.html View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/ad_network_site/testsdk.js View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/chrometest.js View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +65 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/index.html View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/main.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/manifest.json View 0 chunks +-1 lines, --1 lines 0 comments Download
M chrome/test/data/extensions/platform_apps/ad_view/display_first_ad/chrometest.js View 1 2 3 4 5 6 7 8 10 1 chunk +31 lines, -18 lines 0 comments Download
M chrome/test/data/extensions/platform_apps/ad_view/display_first_ad/index.html View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/test/data/extensions/platform_apps/ad_view/display_first_ad/main.js View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/flag_required/chrometest.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +54 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/flag_required/index.html View 1 2 3 4 5 6 7 2 chunks +4 lines, -4 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/flag_required/main.js View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/flag_required/manifest.json View 1 chunk +1 line, -1 line 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/invalid_ad_network/chrometest.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +77 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/invalid_ad_network/index.html View 1 2 3 4 5 6 7 2 chunks +4 lines, -4 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/invalid_ad_network/main.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/invalid_ad_network/manifest.json View 0 chunks +-1 lines, --1 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/load_event/chrometest.js View 1 chunk +0 lines, -15 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/load_event/index.html View 1 chunk +0 lines, -16 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/load_event/main.js View 1 chunk +0 lines, -14 lines 0 comments Download
D chrome/test/data/extensions/platform_apps/ad_view/load_event/manifest.json View 1 chunk +0 lines, -14 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/loadabort_event/chrometest.js View 1 2 3 4 5 6 7 10 1 chunk +32 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/loadabort_event/index.html View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/loadabort_event/main.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/loadabort_event/manifest.json View 0 chunks +-1 lines, --1 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/loadcommit_event/chrometest.js View 1 2 3 4 5 6 7 10 1 chunk +33 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/loadcommit_event/index.html View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/loadcommit_event/main.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/loadcommit_event/manifest.json View 0 chunks +-1 lines, --1 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/onloadcommit_ack/chrometest.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +39 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/onloadcommit_ack/displayad.js View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/onloadcommit_ack/index.html View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/onloadcommit_ack/main.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/onloadcommit_ack/manifest.json View 0 chunks +-1 lines, --1 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/permission_required/chrometest.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +39 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/permission_required/index.html View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/permission_required/main.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/permission_required/manifest.json View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +2 lines, -2 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/properties_exposed/chrometest.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +38 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/properties_exposed/index.html View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/properties_exposed/main.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/properties_exposed/manifest.json View 0 chunks +-1 lines, --1 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/src_flag_required/chrometest.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +34 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/src_flag_required/index.html View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/src_flag_required/main.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/src_flag_required/manifest.json View 0 chunks +-1 lines, --1 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/src_not_exposed/ad_network_fake_website.html View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +6 lines, -2 lines 0 comments Download
A chrome/test/data/extensions/platform_apps/ad_view/src_not_exposed/chrometest.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +30 lines, -0 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/src_not_exposed/index.html View 1 2 3 4 5 6 7 2 chunks +3 lines, -3 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/src_not_exposed/main.js View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +2 lines, -2 lines 0 comments Download
A + chrome/test/data/extensions/platform_apps/ad_view/src_not_exposed/manifest.json View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M content/test/net/url_request_prepackaged_interceptor.h View 1 2 3 4 5 4 chunks +22 lines, -3 lines 0 comments Download
M content/test/net/url_request_prepackaged_interceptor.cc View 1 2 3 4 5 7 chunks +37 lines, -18 lines 0 comments Download

Messages

Total messages: 30 (0 generated)
rpaquay
Add more tests for <adview>, and refactor adview shim. Reviewers, please review the following files: ...
7 years, 9 months ago (2013-03-26 22:15:56 UTC) #1
agl
lgtm https://codereview.chromium.org/12967016/diff/7001/content/test/net/url_request_prepackaged_interceptor.cc File content/test/net/url_request_prepackaged_interceptor.cc (right): https://codereview.chromium.org/12967016/diff/7001/content/test/net/url_request_prepackaged_interceptor.cc#newcode118 content/test/net/url_request_prepackaged_interceptor.cc:118: std::string scheme_; I think these can be const. ...
7 years, 9 months ago (2013-03-26 22:27:16 UTC) #2
asargent_no_longer_on_chrome
+benwells Ben - do you mind reviewing the chrome/{browser,renderer/resources,test/data/}/extensions parts here?
7 years, 9 months ago (2013-03-27 00:14:00 UTC) #3
benwells
Yay for tests! Still looking, but here is early feedback. https://codereview.chromium.org/12967016/diff/7001/chrome/browser/extensions/ad_view_browsertest.cc File chrome/browser/extensions/ad_view_browsertest.cc (right): https://codereview.chromium.org/12967016/diff/7001/chrome/browser/extensions/ad_view_browsertest.cc#newcode46 ...
7 years, 9 months ago (2013-03-27 21:43:05 UTC) #4
rpaquay
Addressed first wave of code review feedback. https://codereview.chromium.org/12967016/diff/7001/chrome/browser/extensions/ad_view_browsertest.cc File chrome/browser/extensions/ad_view_browsertest.cc (right): https://codereview.chromium.org/12967016/diff/7001/chrome/browser/extensions/ad_view_browsertest.cc#newcode46 chrome/browser/extensions/ad_view_browsertest.cc:46: // (image315.png). ...
7 years, 9 months ago (2013-03-27 22:57:25 UTC) #5
benwells
https://chromiumcodereview.appspot.com/12967016/diff/7001/chrome/browser/extensions/ad_view_browsertest.cc File chrome/browser/extensions/ad_view_browsertest.cc (right): https://chromiumcodereview.appspot.com/12967016/diff/7001/chrome/browser/extensions/ad_view_browsertest.cc#newcode122 chrome/browser/extensions/ad_view_browsertest.cc:122: content::URLRequestPrepackagedInterceptor interceptor(scheme, hostname); On 2013/03/27 22:57:25, rpaquay wrote: > ...
7 years, 9 months ago (2013-03-28 00:16:48 UTC) #6
rpaquay
On 2013/03/28 00:16:48, benwells wrote: > https://chromiumcodereview.appspot.com/12967016/diff/7001/chrome/browser/extensions/ad_view_browsertest.cc > File chrome/browser/extensions/ad_view_browsertest.cc (right): > > https://chromiumcodereview.appspot.com/12967016/diff/7001/chrome/browser/extensions/ad_view_browsertest.cc#newcode122 > ...
7 years, 9 months ago (2013-03-28 16:20:46 UTC) #7
benwells
On 2013/03/28 16:20:46, rpaquay wrote: > On 2013/03/28 00:16:48, benwells wrote: > > > https://chromiumcodereview.appspot.com/12967016/diff/7001/chrome/browser/extensions/ad_view_browsertest.cc ...
7 years, 9 months ago (2013-03-28 16:41:54 UTC) #8
rpaquay
Addressing benwells@'s code review feedback.
7 years, 8 months ago (2013-04-01 21:00:33 UTC) #9
benwells
Sorry this is dragging on so long. Unless there is no reason not too I ...
7 years, 8 months ago (2013-04-02 00:49:44 UTC) #10
rpaquay
Addressing benwells@'s code review feedback. I would not too fond of moving the "refactor" into ...
7 years, 8 months ago (2013-04-02 16:44:47 UTC) #11
benwells
Refactor implies there is no change in behavior. If you're fixing things, this isn't a ...
7 years, 8 months ago (2013-04-03 02:40:03 UTC) #12
benwells
https://codereview.chromium.org/12967016/diff/27001/chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/chrometest.js File chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/chrometest.js (right): https://codereview.chromium.org/12967016/diff/27001/chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/chrometest.js#newcode20 chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/chrometest.js:20: setTimeout(function() { On 2013/04/02 16:44:47, rpaquay wrote: > On ...
7 years, 8 months ago (2013-04-03 02:49:47 UTC) #13
rpaquay
Addressing benwells@'s code review feedback. I created a bug and update the description for this ...
7 years, 8 months ago (2013-04-03 18:30:05 UTC) #14
benwells
I looked over ad_view.js and it seems sane to me, but most of it is ...
7 years, 8 months ago (2013-04-04 04:33:51 UTC) #15
rpaquay
Addressing benwells@'s code latest review feedback. https://codereview.chromium.org/12967016/diff/27001/chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/chrometest.js File chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/chrometest.js (right): https://codereview.chromium.org/12967016/diff/27001/chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/chrometest.js#newcode20 chrome/test/data/extensions/platform_apps/ad_view/change_ad_network/chrometest.js:20: setTimeout(function() { On ...
7 years, 8 months ago (2013-04-05 16:12:08 UTC) #16
benwells
Awesome, lgtm. Will leave the ad_view.js change to Fady. On 2013/04/05 16:12:08, rpaquay wrote: > ...
7 years, 8 months ago (2013-04-07 23:47:04 UTC) #17
Fady Samuel
The code cleanup in ad_view.js is good. LGTM with one nit. https://codereview.chromium.org/12967016/diff/63014/chrome/renderer/resources/extensions/ad_view.js File chrome/renderer/resources/extensions/ad_view.js (right): ...
7 years, 8 months ago (2013-04-09 21:15:38 UTC) #18
rpaquay
On 2013/04/09 21:15:38, Fady Samuel wrote: > The code cleanup in ad_view.js is good. LGTM ...
7 years, 8 months ago (2013-04-22 17:19:18 UTC) #19
rpaquay
Rebasing. https://codereview.chromium.org/12967016/diff/63014/chrome/renderer/resources/extensions/ad_view.js File chrome/renderer/resources/extensions/ad_view.js (right): https://codereview.chromium.org/12967016/diff/63014/chrome/renderer/resources/extensions/ad_view.js#newcode405 chrome/renderer/resources/extensions/ad_view.js:405: //this.browserPluginNode_.setAttribute('src', newValue); On 2013/04/09 21:15:38, Fady Samuel wrote: ...
7 years, 8 months ago (2013-04-22 17:20:08 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rpaquay@chromium.org/12967016/105001
7 years, 8 months ago (2013-04-22 17:22:13 UTC) #21
commit-bot: I haz the power
Presubmit check for 12967016-105001 failed and returned exit status 1. INFO:root:Found 55 file(s). Running presubmit ...
7 years, 8 months ago (2013-04-22 17:22:40 UTC) #22
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rpaquay@chromium.org/12967016/105001
7 years, 8 months ago (2013-04-22 17:35:14 UTC) #23
commit-bot: I haz the power
Presubmit check for 12967016-105001 failed and returned exit status -2001. The presubmit check was hung. ...
7 years, 8 months ago (2013-04-22 17:41:47 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rpaquay@chromium.org/12967016/105001
7 years, 8 months ago (2013-04-22 18:11:20 UTC) #25
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
7 years, 8 months ago (2013-04-22 18:39:07 UTC) #26
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rpaquay@chromium.org/12967016/134001
7 years, 8 months ago (2013-04-22 19:42:48 UTC) #27
commit-bot: I haz the power
Retried try job too often on linux_rel for step(s) browser_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=linux_rel&number=119399
7 years, 8 months ago (2013-04-22 21:12:53 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rpaquay@chromium.org/12967016/147001
7 years, 8 months ago (2013-04-23 22:22:10 UTC) #29
commit-bot: I haz the power
7 years, 8 months ago (2013-04-24 05:10:10 UTC) #30
Message was sent while issue was closed.
Change committed as 196036

Powered by Google App Engine
This is Rietveld 408576698