Bug 85134

Summary: [GTK] DRT needs an implementation of LayoutTestController::setDefersLoading and ::goBack
Product: WebKit Reporter: Sudarsana Nagineni (babu) <naginenis>
Component: WebKitGTKAssignee: Sudarsana Nagineni (babu) <naginenis>
Status: RESOLVED FIXED    
Severity: Normal CC: gustavo, mrobinson, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
mrobinson: review+, webkit.review.bot: commit-queue-
patch none

Description Sudarsana Nagineni (babu) 2012-04-28 04:26:11 PDT
Add support for LayoutTestController::setDefersLoading and ::goBack to enable the following test.
loader/navigation-while-deferring-loads.html
Comment 1 Sudarsana Nagineni (babu) 2012-04-30 05:44:14 PDT
Created attachment 139436 [details]
Patch

Implement LayoutTestController::setDefersLoading and ::goBack
Comment 2 WebKit Review Bot 2012-04-30 05:47:02 PDT
Attachment 139436 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'LayoutTests/ChangeLog', u'LayoutTests/plat..." exit_code: 1
LayoutTests/platform/gtk/test_expectations.txt:514:  More specific entry on line 325 overrides line 514 fast/workers/storage/use-same-database-in-page-and-workers.html  [test/expectations] [5]
Total errors found: 1 in 8 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Sudarsana Nagineni (babu) 2012-04-30 06:36:14 PDT
(In reply to comment #2)
> Attachment 139436 [details] did not pass style-queue:
> 
> Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'LayoutTests/ChangeLog', u'LayoutTests/plat..." exit_code: 1
> LayoutTests/platform/gtk/test_expectations.txt:514:  More specific entry on line 325 overrides line 514 fast/workers/storage/use-same-database-in-page-and-workers.html  [test/expectations] [5]
> Total errors found: 1 in 8 files
> 
> 
> If any of these errors are false positives, please file a bug against check-webkit-style.

Looks like this is because of duplicate entry of same test with different expectations.

line 325: BUGWK56147 DEBUG : fast/workers/storage/use-same-database-in-page-and-workers.html = CRASH

line 514: BUGWK84859 : fast/workers/storage/use-same-database-in-page-and-workers.html = PASS TEXT
Comment 4 Martin Robinson 2012-04-30 09:45:55 PDT
Comment on attachment 139436 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=139436&action=review

> LayoutTests/platform/gtk/test_expectations.txt:367
> +BUGWK85159 DEBUG : loader/load-defer-resume-crash.html = CRASH

Are you sure this crashes in DumpRenderTree as well as GtkLauncher?
Comment 5 Sudarsana Nagineni (babu) 2012-04-30 10:22:45 PDT
(In reply to comment #4)
> (From update of attachment 139436 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=139436&action=review
> 
> > LayoutTests/platform/gtk/test_expectations.txt:367
> > +BUGWK85159 DEBUG : loader/load-defer-resume-crash.html = CRASH
> 
> Are you sure this crashes in DumpRenderTree as well as GtkLauncher?

Yes, loading the test case in DRT also causes an assertion failure with the patch.
Comment 6 Gustavo Noronha (kov) 2012-05-02 18:15:53 PDT
(In reply to comment #3)
> > If any of these errors are false positives, please file a bug against check-webkit-style.
> 
> Looks like this is because of duplicate entry of same test with different expectations.
> 
> line 325: BUGWK56147 DEBUG : fast/workers/storage/use-same-database-in-page-and-workers.html = CRASH
> 
> line 514: BUGWK84859 : fast/workers/storage/use-same-database-in-page-and-workers.html = PASS TEXT

FWIW, I removed the CRASH line, and added a comment on the PASS pointing to the cross-platform bug that tracks the 'some times asserts' problem.
Comment 7 Sudarsana Nagineni (babu) 2012-05-04 07:47:40 PDT
Created attachment 140224 [details]
Patch

removed load-defer-resume-crash.html from test expectations since it is going to be fixed in 85159.
Comment 8 Martin Robinson 2012-05-04 09:00:00 PDT
Comment on attachment 140224 [details]
Patch

How does goBack differ from the history.back()?
Comment 9 Sudarsana Nagineni (babu) 2012-05-04 10:03:45 PDT
(In reply to comment #8)
> (From update of attachment 140224 [details])
> How does goBack differ from the history.back()?

Only the difference I see here is history.goback() calls NavigationScheduler first.

#0  WebCore::Page::goToItem (this=0x678400, item=0xc5b410, type=WebCore::FrameLoadTypeIndexedBackForward) at ../../Source/WebCore/page/Page.cpp:358
#1  0x00007ffff3b74f51 in WebCore::Page::goBackOrForward (this=0x678400, distance=-1) at ../../Source/WebCore/page/Page.cpp:353
#2  0x00007ffff3817449 in WebCore::BackForwardController::goBackOrForward (this=0x6679c0, distance=-1) at ../../Source/WebCore/history/BackForwardController.cpp:59
#3  0x00007ffff3ad260a in WebCore::ScheduledHistoryNavigation::fire (this=0x7fff940cf900, frame=0x680de0) at ../../Source/WebCore/loader/NavigationScheduler.cpp:205
#4  0x00007ffff3ad147d in WebCore::NavigationScheduler::timerFired (this=0x681258) at ../../Source/WebCore/loader/NavigationScheduler.cpp:418
Comment 10 Martin Robinson 2012-05-04 10:35:35 PDT
Comment on attachment 140224 [details]
Patch

Thanks!
Comment 11 WebKit Review Bot 2012-05-04 10:50:42 PDT
Comment on attachment 140224 [details]
Patch

Rejecting attachment 140224 [details] from commit-queue.

Failed to run "['/mnt/git/webkit-commit-queue/Tools/Scripts/webkit-patch', '--status-host=queues.webkit.org', '-..." exit_code: 2

Last 500 characters of output:
t-commit-queue/Source/WebKit/chromium/third_party/v8-i18n --revision 32 --non-interactive --force --accept theirs-conflict --ignore-externals' in '/mnt/git/webkit-commit-queue/Source/WebKit/chromium'
46>At revision 32.

________ running '/usr/bin/python tools/clang/scripts/update.py --mac-only' in '/mnt/git/webkit-commit-queue/Source/WebKit/chromium'

________ running '/usr/bin/python gyp_webkit' in '/mnt/git/webkit-commit-queue/Source/WebKit/chromium'
Updating webkit projects from gyp files...

Full output: http://queues.webkit.org/results/12626190
Comment 12 Sudarsana Nagineni (babu) 2012-05-04 11:41:56 PDT
Created attachment 140288 [details]
patch

rebased. Thanks for review Martin!
Comment 13 WebKit Review Bot 2012-05-04 12:44:23 PDT
Comment on attachment 140288 [details]
patch

Clearing flags on attachment: 140288

Committed r116146: <http://trac.webkit.org/changeset/116146>
Comment 14 WebKit Review Bot 2012-05-04 12:44:29 PDT
All reviewed patches have been landed.  Closing bug.