New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 866140 link

Starred by 1 user

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

content_shell and LayoutTests are complicated for historical reasons

Project Member Reported by danakj@chromium.org, Jul 20

Issue description

Much of the LayoutTest harness was in WebKit so it is used through abstractions that are no longer needed with it all being in content/ now.

content_shell is a testonly=true target because it always builds in layout test code, and content/test/ which allows it to circumvent the content/public/ APIs, so we can't have confidence that content public APIs are truly sufficient for content_shell.

We should
1) Avoid unneeded abstractions within the layout test code. Inject into production directly with interface overrides where needed.
2) Be able to build content_shell without include content/test/ or content/shell/.../layout_test/.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Jul 27

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1fa4591ecc787726b8a7071090e4a7b8b61b57dd

commit 1fa4591ecc787726b8a7071090e4a7b8b61b57dd
Author: danakj <danakj@chromium.org>
Date: Fri Jul 27 18:58:06 2018

Merge all content_shell renderer layout_test code.

R=dcheng@chromium.org
TBR=jochen@chromium.org

Currently layout test code is split over:

- content/shell/test_runner/ (separate component)
Has renderer-side code, is allowed to use content/renderer/, does not
use content/shell/renderer/.

- content/shell/renderer/layout_test/ (part of content_shell_lib)
Has renderer-side code, makes light use of content/shell/renderer/, but is
not able to use content/renderer/.

- content/shell/browser/layout_test/ (part of content_shell_lib)
Has browser-side code, makes heavy use of content/shell/browser/, but is
not able to use content/browser/.

- content/public/test/layouttest_support.h
Header for access to content/renderer/ things and content/browser/
things. Used by content/shell/renderer/layout_test/ and
content/shell/browser/layout_test/.

- content/test/layouttest_support.cc
Impls for access to content/renderer/ and content/browser/ things.


This patch aims to
1. Combine the test_runner/ and shell/renderer/layout_test/ pieces of
code so they don't need to use indirections to interact. Their
separation is a legacy of test_runner/ being implemented inside blink
(WebKit) in the past.
2. Move layouttest_support.h out of content/public/ and the .cc out of
content/test/ to a layout_test-specific code location.

To do (1), test_runner/* moves to shell/renderer/layout_test/*. This
is fairly straight forward. We remove the TEST_RUNNER_EXPORT macro
as they are now part of a static library. They are left in the
test_runner namespace at the moment.

To do (2), we move layouttest_support.(cc|h) to
shell/renderer/layout_test/. There are 3 methods in the file that
are called from shell/browser/layout_test/ and use content/browser
so we split those out to shell/browser/layout_test/.

However this causes a problem that content_shell_lib will depend
on content/{browser,child,renderer}/ via the layouttest_support.cc
file. To avoid this, we
- Move content/shell/renderer/layout_test/* into a separate build
target called //content/shell:layout_test_renderer_lib and we
give it visibility to content/renderer/ and content/child/.
- Move content/shell/browser/layout_test/layouttest_support.* into
a separate build target called
//content/shell:browser_layout_test_support_lib. We don't move all
of content/shell/browser/layout_test/* because of heavy interaction
between it and its parent directory at this time.
- For a few files used by the shell/renderer/ (and shell/) and
shell/renderer/layout_test/ directories, we move them out to a
shared library as well, called
//content/shell:content_shell_renderer_common_lib.
- And for the common/layout_test/layout_test_switches.cc files,
which are used in both, but we'd like to not leak out of
content_shell_lib since they are part of .../layout_test/, we
make a non-public dep on //content/shell:content_shell_common_test_lib

Ideally, I think we have a separate library for
//content/shell/browser/layout_test
//content/shell/common/layout_test
//content/shell/renderer/layout_test

But we need better indirection between the content_shell_lib and
the .../layout_test/ code in order to do that. Once it was so, we
would be closer to making it possible to have a content_shell build
target that does not include any test code (and thus truly only uses
the public APIs), and a separate content_shell-like build target
that includes the layout test code.

Bug: 866140
Change-Id: Ia39f7385711bdb610948a07fd473ad9b346b82ae
Reviewed-on: https://chromium-review.googlesource.com/1145644
Reviewed-by: danakj <danakj@chromium.org>
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/master@{#578734}
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/components/BUILD.gn
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/browser/BUILD.gn
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/child/BUILD.gn
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/public/test/content_browser_test.cc
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/renderer/BUILD.gn
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/BUILD.gn
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/app/shell_main_delegate.cc
[add] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/browser/layout_test/DEPS
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/browser/layout_test/blink_test_controller.cc
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/browser/layout_test/fake_bluetooth_chooser.cc
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/browser/layout_test/layout_test_bluetooth_fake_adapter_setter_impl.cc
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/browser/layout_test/layout_test_message_filter.cc
[add] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/browser/layout_test/layouttest_support.cc
[add] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/browser/layout_test/layouttest_support.h
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/DEPS
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/DEPS
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/OWNERS
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/accessibility_controller.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/accessibility_controller.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/app_banner_service.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/app_banner_service.h
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/blink_test_helpers.cc
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/blink_test_runner.cc
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/blink_test_runner.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/event_sender.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/event_sender.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/gamepad_controller.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/gamepad_controller.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/gc_controller.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/gc_controller.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layout_and_paint_async_then.cc
[add] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layout_and_paint_async_then.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layout_dump.cc
[add] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layout_dump.h
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layout_test_content_renderer_client.cc
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layout_test_render_frame_observer.cc
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layout_test_render_thread_observer.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layout_test_runtime_flags.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layout_test_runtime_flags.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layouttest_support.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/layouttest_support.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_content_settings_client.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_content_settings_client.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_grammar_check.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_grammar_check.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_screen_orientation_client.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_screen_orientation_client.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_spell_check.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_spell_check.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_web_document_subresource_filter.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_web_document_subresource_filter.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_web_midi_accessor.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_web_midi_accessor.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_web_theme_engine.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/mock_web_theme_engine.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/pixel_dump.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/pixel_dump.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/ChromiumAATTest.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/WebKitWeightWatcher100.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/WebKitWeightWatcher200.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/WebKitWeightWatcher300.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/WebKitWeightWatcher400.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/WebKitWeightWatcher500.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/WebKitWeightWatcher600.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/WebKitWeightWatcher700.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/WebKitWeightWatcher800.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/WebKitWeightWatcher900.ttf
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/android_fallback_fonts.xml
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/resources/fonts/android_main_fonts.xml
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/spell_check_client.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/spell_check_client.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_common.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_common.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_interfaces.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_interfaces.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_plugin.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_plugin.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_preferences.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_preferences.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_runner.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_runner.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_runner_for_specific_view.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_runner_for_specific_view.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_runner_support.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/test_runner_support.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/text_input_controller.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/text_input_controller.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/tracked_dictionary.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/tracked_dictionary.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_ax_object_proxy.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_ax_object_proxy.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_frame_test_client.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_frame_test_client.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_frame_test_proxy.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_frame_test_proxy.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_test_delegate.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_test_interfaces.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_test_interfaces.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_test_runner.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_view_test_client.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_view_test_client.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_view_test_proxy.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_view_test_proxy.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_widget_test_client.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_widget_test_client.h
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_widget_test_proxy.cc
[rename] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/shell/renderer/layout_test/web_widget_test_proxy.h
[delete] https://crrev.com/0762f5438d83c59af84b717ae3a6982e54eba37b/content/shell/test_runner/layout_and_paint_async_then.h
[delete] https://crrev.com/0762f5438d83c59af84b717ae3a6982e54eba37b/content/shell/test_runner/layout_dump.h
[delete] https://crrev.com/0762f5438d83c59af84b717ae3a6982e54eba37b/content/shell/test_runner/test_runner_export.h
[modify] https://crrev.com/1fa4591ecc787726b8a7071090e4a7b8b61b57dd/content/test/BUILD.gn

Project Member

Comment 2 by bugdroid1@chromium.org, Jul 27

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/fdda96d49f80bcafe93f246d73e02361d9308d6e

commit fdda96d49f80bcafe93f246d73e02361d9308d6e
Author: Scott Violet <sky@chromium.org>
Date: Fri Jul 27 20:17:23 2018

Revert "Merge all content_shell renderer layout_test code."

This reverts commit 1fa4591ecc787726b8a7071090e4a7b8b61b57dd.

Reason for revert: In hopes of greening tree. Sample failure from https://ci.chromium.org/p/chromium/builders/luci.chromium.ci/Win/71221 : (see the compile no-op stage)

ninja explain: output obj/content/test/nested_message_pump_android.lib doesn't exist
ninja explain: obj/content/test/nested_message_pump_android.lib is dirty

Original change's description:
> Merge all content_shell renderer layout_test code.
> 
> R=​dcheng@chromium.org
> TBR=jochen@chromium.org
> 
> Currently layout test code is split over:
> 
> - content/shell/test_runner/ (separate component)
> Has renderer-side code, is allowed to use content/renderer/, does not
> use content/shell/renderer/.
> 
> - content/shell/renderer/layout_test/ (part of content_shell_lib)
> Has renderer-side code, makes light use of content/shell/renderer/, but is
> not able to use content/renderer/.
> 
> - content/shell/browser/layout_test/ (part of content_shell_lib)
> Has browser-side code, makes heavy use of content/shell/browser/, but is
> not able to use content/browser/.
> 
> - content/public/test/layouttest_support.h
> Header for access to content/renderer/ things and content/browser/
> things. Used by content/shell/renderer/layout_test/ and
> content/shell/browser/layout_test/.
> 
> - content/test/layouttest_support.cc
> Impls for access to content/renderer/ and content/browser/ things.
> 
> 
> This patch aims to
> 1. Combine the test_runner/ and shell/renderer/layout_test/ pieces of
> code so they don't need to use indirections to interact. Their
> separation is a legacy of test_runner/ being implemented inside blink
> (WebKit) in the past.
> 2. Move layouttest_support.h out of content/public/ and the .cc out of
> content/test/ to a layout_test-specific code location.
> 
> To do (1), test_runner/* moves to shell/renderer/layout_test/*. This
> is fairly straight forward. We remove the TEST_RUNNER_EXPORT macro
> as they are now part of a static library. They are left in the
> test_runner namespace at the moment.
> 
> To do (2), we move layouttest_support.(cc|h) to
> shell/renderer/layout_test/. There are 3 methods in the file that
> are called from shell/browser/layout_test/ and use content/browser
> so we split those out to shell/browser/layout_test/.
> 
> However this causes a problem that content_shell_lib will depend
> on content/{browser,child,renderer}/ via the layouttest_support.cc
> file. To avoid this, we
> - Move content/shell/renderer/layout_test/* into a separate build
> target called //content/shell:layout_test_renderer_lib and we
> give it visibility to content/renderer/ and content/child/.
> - Move content/shell/browser/layout_test/layouttest_support.* into
> a separate build target called
> //content/shell:browser_layout_test_support_lib. We don't move all
> of content/shell/browser/layout_test/* because of heavy interaction
> between it and its parent directory at this time.
> - For a few files used by the shell/renderer/ (and shell/) and
> shell/renderer/layout_test/ directories, we move them out to a
> shared library as well, called
> //content/shell:content_shell_renderer_common_lib.
> - And for the common/layout_test/layout_test_switches.cc files,
> which are used in both, but we'd like to not leak out of
> content_shell_lib since they are part of .../layout_test/, we
> make a non-public dep on //content/shell:content_shell_common_test_lib
> 
> Ideally, I think we have a separate library for
> //content/shell/browser/layout_test
> //content/shell/common/layout_test
> //content/shell/renderer/layout_test
> 
> But we need better indirection between the content_shell_lib and
> the .../layout_test/ code in order to do that. Once it was so, we
> would be closer to making it possible to have a content_shell build
> target that does not include any test code (and thus truly only uses
> the public APIs), and a separate content_shell-like build target
> that includes the layout test code.
> 
> Bug: 866140
> Change-Id: Ia39f7385711bdb610948a07fd473ad9b346b82ae
> Reviewed-on: https://chromium-review.googlesource.com/1145644
> Reviewed-by: danakj <danakj@chromium.org>
> Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
> Reviewed-by: Daniel Cheng <dcheng@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#578734}

TBR=dgozman@chromium.org,danakj@chromium.org,dcheng@chromium.org,jochen@chromium.org

Change-Id: Ie61b12dcfc00e5c59cf0c5e3137b305d957cb261
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 866140
Reviewed-on: https://chromium-review.googlesource.com/1153611
Reviewed-by: Scott Violet <sky@chromium.org>
Commit-Queue: Scott Violet <sky@chromium.org>
Cr-Commit-Position: refs/heads/master@{#578764}
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/components/BUILD.gn
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/browser/BUILD.gn
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/child/BUILD.gn
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/public/test/content_browser_test.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/public/test/layouttest_support.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/public/test/test_runner_support.h
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/renderer/BUILD.gn
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/BUILD.gn
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/app/shell_main_delegate.cc
[delete] https://crrev.com/e61e11df4f49d39d2fa9d01727da9a9a892acdd5/content/shell/browser/layout_test/DEPS
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/browser/layout_test/blink_test_controller.cc
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/browser/layout_test/fake_bluetooth_chooser.cc
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/browser/layout_test/layout_test_bluetooth_fake_adapter_setter_impl.cc
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/browser/layout_test/layout_test_message_filter.cc
[delete] https://crrev.com/e61e11df4f49d39d2fa9d01727da9a9a892acdd5/content/shell/browser/layout_test/layouttest_support.cc
[delete] https://crrev.com/e61e11df4f49d39d2fa9d01727da9a9a892acdd5/content/shell/browser/layout_test/layouttest_support.h
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/renderer/DEPS
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/renderer/layout_test/blink_test_helpers.cc
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/renderer/layout_test/blink_test_runner.cc
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/renderer/layout_test/blink_test_runner.h
[delete] https://crrev.com/e61e11df4f49d39d2fa9d01727da9a9a892acdd5/content/shell/renderer/layout_test/layout_and_paint_async_then.h
[delete] https://crrev.com/e61e11df4f49d39d2fa9d01727da9a9a892acdd5/content/shell/renderer/layout_test/layout_dump.h
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/renderer/layout_test/layout_test_content_renderer_client.cc
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/renderer/layout_test/layout_test_render_frame_observer.cc
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/renderer/layout_test/layout_test_render_thread_observer.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/DEPS
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/OWNERS
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/accessibility_controller.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/accessibility_controller.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/app_banner_service.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/app_banner_service.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/event_sender.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/event_sender.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/gamepad_controller.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/gamepad_controller.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/gc_controller.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/gc_controller.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/layout_and_paint_async_then.cc
[add] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/layout_and_paint_async_then.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/layout_dump.cc
[add] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/layout_dump.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/layout_test_runtime_flags.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/layout_test_runtime_flags.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_content_settings_client.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_content_settings_client.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_grammar_check.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_grammar_check.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_screen_orientation_client.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_screen_orientation_client.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_spell_check.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_spell_check.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_web_document_subresource_filter.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_web_document_subresource_filter.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_web_midi_accessor.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_web_midi_accessor.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_web_theme_engine.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/mock_web_theme_engine.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/pixel_dump.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/pixel_dump.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/ChromiumAATTest.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/WebKitWeightWatcher100.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/WebKitWeightWatcher200.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/WebKitWeightWatcher300.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/WebKitWeightWatcher400.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/WebKitWeightWatcher500.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/WebKitWeightWatcher600.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/WebKitWeightWatcher700.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/WebKitWeightWatcher800.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/WebKitWeightWatcher900.ttf
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/android_fallback_fonts.xml
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/resources/fonts/android_main_fonts.xml
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/spell_check_client.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/spell_check_client.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_common.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_common.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_interfaces.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_interfaces.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_plugin.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_plugin.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_preferences.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_preferences.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_runner.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_runner.h
[add] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_runner_export.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_runner_for_specific_view.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/test_runner_for_specific_view.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/text_input_controller.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/text_input_controller.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/tracked_dictionary.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/tracked_dictionary.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_ax_object_proxy.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_ax_object_proxy.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_frame_test_client.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_frame_test_client.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_frame_test_proxy.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_frame_test_proxy.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_test_delegate.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_test_interfaces.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_test_interfaces.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_test_runner.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_view_test_client.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_view_test_client.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_view_test_proxy.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_view_test_proxy.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_widget_test_client.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_widget_test_client.h
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_widget_test_proxy.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/shell/test_runner/web_widget_test_proxy.h
[modify] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/test/BUILD.gn
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/test/layouttest_support.cc
[rename] https://crrev.com/fdda96d49f80bcafe93f246d73e02361d9308d6e/content/test/test_runner_support.cc

Components: -Internals

Sign in to add a comment