Bug 159325 - Web Inspector: Fix inspector/debugger/pause-reason.html
Summary: Web Inspector: Fix inspector/debugger/pause-reason.html
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (show other bugs)
Version: WebKit Nightly Build
Hardware: All All
: P2 Normal
Assignee: Joseph Pecoraro
URL:
Keywords: DoNotImportToRadar
: 151893 (view as bug list)
Depends on:
Blocks:
 
Reported: 2016-06-30 17:58 PDT by Joseph Pecoraro
Modified: 2016-07-02 20:32 PDT (History)
8 users (show)

See Also:


Attachments
[PATCH] Proposed Fix (2.53 KB, patch)
2016-06-30 18:04 PDT, Joseph Pecoraro
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph Pecoraro 2016-06-30 17:58:40 PDT
Summary:
This test currently fails.

Steps to Reproduce:
1. shell> run-webkit-tests --force inspector/debugger/pause-reason.html
  => Fail

Notes:
Seems to fail because we don't pause where we expect to pause due to test behavior.
Change the "pause on next statement" to not pause on inspector code, but instead pause on page code.
Comment 1 Joseph Pecoraro 2016-06-30 18:03:47 PDT
*** Bug 151893 has been marked as a duplicate of this bug. ***
Comment 2 Joseph Pecoraro 2016-06-30 18:04:22 PDT
Created attachment 282499 [details]
[PATCH] Proposed Fix
Comment 3 Brian Burg 2016-07-01 09:07:37 PDT
Comment on attachment 282499 [details]
[PATCH] Proposed Fix

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

> LayoutTests/inspector/debugger/pause-reason.html:33
>              test.setup();

If there are other evaluateOnPage things queued up, how do we guarantee that the pause will be on test.expression and not some other expression?
Comment 4 Joseph Pecoraro 2016-07-01 11:36:50 PDT
(In reply to comment #3)
> Comment on attachment 282499 [details]
> [PATCH] Proposed Fix
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=282499&action=review
> 
> > LayoutTests/inspector/debugger/pause-reason.html:33
> >              test.setup();
> 
> If there are other evaluateOnPage things queued up, how do we guarantee that
> the pause will be on test.expression and not some other expression?

I'm not sure there is a way we can guarantee this.

This test is testing evaluateInPage + pause on next statement. If anything happens in between the test will be broken. That said, one possible solution might be evaluateInPage where the Runtime.evaluate options include doNotPauseOnExceptionsAndMuteConsole:true to evaluate a "setTimeout(something,0)". Not sure that is much better.

What do you think?
Comment 5 WebKit Commit Bot 2016-07-02 20:32:47 PDT
Comment on attachment 282499 [details]
[PATCH] Proposed Fix

Clearing flags on attachment: 282499

Committed r202783: <http://trac.webkit.org/changeset/202783>
Comment 6 WebKit Commit Bot 2016-07-02 20:32:51 PDT
All reviewed patches have been landed.  Closing bug.