WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
92010
[Chromium] Move layoutTestMode to WebCore
https://bugs.webkit.org/show_bug.cgi?id=92010
Summary
[Chromium] Move layoutTestMode to WebCore
Mark Pilgrim (Google)
Reported
2012-07-23 10:45:42 PDT
[Chromium] Move layoutTestMode to WebCore
Attachments
Patch
(41.99 KB, patch)
2012-07-23 10:46 PDT
,
Mark Pilgrim (Google)
no flags
Details
Formatted Diff
Diff
Patch
(41.70 KB, patch)
2012-07-23 11:56 PDT
,
Mark Pilgrim (Google)
no flags
Details
Formatted Diff
Diff
Patch
(41.73 KB, patch)
2012-07-23 19:34 PDT
,
Mark Pilgrim (Google)
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Mark Pilgrim (Google)
Comment 1
2012-07-23 10:46:33 PDT
Created
attachment 153818
[details]
Patch
Mark Pilgrim (Google)
Comment 2
2012-07-23 10:47:31 PDT
Does not currently compile.
Mark Pilgrim (Google)
Comment 3
2012-07-23 10:55:33 PDT
Correction: compiles, does not link. out/Release/../../Source/WebKit/chromium/third_party/gold/gold64: out/Release/obj.target/Source/WebKit/chromium/libwebkit.a(out/Release/obj.target/Source/WebKit/chromium/../../../webkit/Source/WebKit/chromium/src/WebKit.o): in function WebKit::setLayoutTestMode(bool):WebKit.cpp(.text._ZN6WebKit17setLayoutTestModeEb+0x5): error: undefined reference to 'WebCore::LayoutTestMode::setLayoutTestMode(bool)' out/Release/../../Source/WebKit/chromium/third_party/gold/gold64: out/Release/obj.target/Source/WebCore/WebCore.gyp/libwebcore_rendering.a(out/Release/obj.target/Source/WebCore/WebCore.gyp/../../../webcore_rendering/Source/WebCore/rendering/RenderThemeChromiumSkia.o): in function WebCore::RenderThemeChromiumSkia::caretBlinkInterval() const:RenderThemeChromiumSkia.cpp(.text._ZNK7WebCore23RenderThemeChromiumSkia18caretBlinkIntervalEv+0x5): error: undefined reference to 'WebCore::LayoutTestMode::layoutTestMode()' collect2: ld returned 1 exit status make: *** [out/Release/TestWebKitAPI] Error 1 zsh: exit 2 Tools/Scripts/build-webkit --chromium And other such niceness.
Ryosuke Niwa
Comment 4
2012-07-23 11:09:02 PDT
I don't think we should be moving a class about layout test into WebCore. That to me is a layer violation.
Adam Barth
Comment 5
2012-07-23 11:11:58 PDT
Comment on
attachment 153818
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=153818&action=review
> Source/WebCore/platform/LayoutTestMode.h:39 > +class LayoutTestMode { > +public: > + static bool layoutTestMode(); > + static void setLayoutTestMode(bool);
We don't really need this class wrapper. We can just have layoutTestMode() and setLayoutTestMode() exist in the WebCore namespace.
> Source/WebCore/platform/LayoutTestMode.h:44 > + static bool isLayoutTestModeEnabled;
In that approach, this can just be a static in the LayoutTestMode.cpp file. We might take this opportunity to rename these functions to isRunningLayoutTest() or something else more WebKity.
Adam Barth
Comment 6
2012-07-23 11:13:25 PDT
Comment on
attachment 153818
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=153818&action=review
> Source/WebCore/WebCore.gypi:290 > + 'platform/LayoutTestMode.h',
Looks like you didn't add platform/LayoutTestMode.cpp to WebCore.gypi, which is likely what's causing your linking trouble.
WebKit Review Bot
Comment 7
2012-07-23 11:30:28 PDT
Comment on
attachment 153818
[details]
Patch
Attachment 153818
[details]
did not pass chromium-ews (chromium-xvfb): Output:
http://queues.webkit.org/results/13329107
Darin Fisher (:fishd, Google)
Comment 8
2012-07-23 11:45:12 PDT
(In reply to
comment #4
)
> I don't think we should be moving a class about layout test into WebCore. That to me is a layer violation.
This is not a new dependency. You can see that in the Chromium port, WebCore already knows about this "layout test" boolean. Mark is just moving it from one spot in WebCore to another.
Mark Pilgrim (Google)
Comment 9
2012-07-23 11:56:28 PDT
Created
attachment 153826
[details]
Patch
Mark Pilgrim (Google)
Comment 10
2012-07-23 11:57:20 PDT
(In reply to
comment #5
)
> (From update of
attachment 153818
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=153818&action=review
> > > Source/WebCore/platform/LayoutTestMode.h:39 > > +class LayoutTestMode { > > +public: > > + static bool layoutTestMode(); > > + static void setLayoutTestMode(bool); > > We don't really need this class wrapper.
Removed in latest patch.
> > > Source/WebCore/platform/LayoutTestMode.h:44 > > + static bool isLayoutTestModeEnabled; > > In that approach, this can just be a static in the LayoutTestMode.cpp file. > > We might take this opportunity to rename these functions to isRunningLayoutTest() or something else more WebKity.
Renamed in latest patch.
Mark Pilgrim (Google)
Comment 11
2012-07-23 11:57:55 PDT
(In reply to
comment #6
)
> (From update of
attachment 153818
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=153818&action=review
> > > Source/WebCore/WebCore.gypi:290 > > + 'platform/LayoutTestMode.h', > > Looks like you didn't add platform/LayoutTestMode.cpp to WebCore.gypi, which is likely what's causing your linking trouble.
Thanks. Added in latest patch.
Adam Barth
Comment 12
2012-07-23 13:28:43 PDT
Comment on
attachment 153826
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=153826&action=review
> Source/WebCore/platform/LayoutTestMode.h:32 > +#ifndef LayoutTestMode_h > +#define LayoutTestMode_h
I wonder if LayoutTestMode.h is still the right name for this header... Perhaps LayoutTestSupport.h (just LayoutTest.h doesn't seem right)? Sorry to be so nit-picky about the names. If you want to land it with this name, that's fine too.
Mark Pilgrim (Google)
Comment 13
2012-07-23 19:34:06 PDT
Created
attachment 153939
[details]
Patch
Mark Pilgrim (Google)
Comment 14
2012-07-23 19:34:49 PDT
Comment on
attachment 153939
[details]
Patch Renamed to LayoutTestSupport.
WebKit Review Bot
Comment 15
2012-07-23 22:05:47 PDT
Comment on
attachment 153939
[details]
Patch Clearing flags on attachment: 153939 Committed
r123424
: <
http://trac.webkit.org/changeset/123424
>
WebKit Review Bot
Comment 16
2012-07-23 22:05:54 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug