Re: [webkit-dev] make-script-test-wrappers not being maintained

2011-09-12 Thread Maciej Stachowiak

On Sep 8, 2011, at 11:15 AM, Eric Seidel wrote:

> It seems the "sucessfullyParsed" question could also be answered by
> some intelligent onerror handler added to the right script tag.

The "successfullyParsed" thing was originally added to benefit JS tests running 
in the browser. If you get a bunch of passes and then an exception which 
prevents further output, you wouldn't think that everything passed solely 
because the output is truncated. If it's possible to achieve this with onerror, 
and if this technique works cross-browser (an important use case for 
assertion-style layout tests is to load them in other browsers), then that 
would be fine by me. Last I heard, Opera didn't support onerror properly, but 
this may have changed.

 - Maciej

___
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev


Re: [webkit-dev] make-script-test-wrappers not being maintained

2011-09-08 Thread Eric Seidel
It seems the "sucessfullyParsed" question could also be answered by
some intelligent onerror handler added to the right script tag.

On Thu, Sep 8, 2011 at 10:16 AM, Ryosuke Niwa  wrote:
> Yeah, if the script is located at LayoutTests/resources/js-test.js for
> example, all I need to type is
> 
> 
> or
> 
> 
> ...
> that seems like a trivial step to me. However, I've always felt having to
> add var successfullyParsed = true to be annoying. Can we get rid of this
> variable altogether since any parsing error shows on console anyway?
> - Ryosuke
> On Thu, Sep 8, 2011 at 10:11 AM, Ojan Vafai  wrote:
>>
>> On Thu, Sep 8, 2011 at 12:58 AM, Ryosuke Niwa  wrote:
>>>
>>> On Thu, Sep 8, 2011 at 12:41 AM, Maciej Stachowiak  wrote:

 Do you have an idea for how to avoid needing to adjust the number of
 "../" path segments in the path to the harness? That's the most annoying
 step of the current copy/paste solution, and it does not seem like
 simplifying the boilerplate as you suggest resolves that issue.
>>>
>>> I personally don't think it be that annoying. Usually, I can find another
>>> test that uses the same framework in the same depth.  I'd be more annoyed by
>>> having to run a script on Terminal (and presumably giving it a relative path
>>> from LayoutTests).
>>
>> Like Ryosuke, I haven't found this to be much of a nuisance in practice
>> with dump-as-markup.js since there's only one path you need to fix up.
>
> ___
> webkit-dev mailing list
> webkit-dev@lists.webkit.org
> http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
>
>
___
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev


Re: [webkit-dev] make-script-test-wrappers not being maintained

2011-09-08 Thread Ryosuke Niwa
Yeah, if the script is located at LayoutTests/resources/js-test.js for
example, all I need to type is


or


...

that seems like a trivial step to me. However, I've always felt having to
add var successfullyParsed = true to be annoying. Can we get rid of this
variable altogether since any parsing error shows on console anyway?

- Ryosuke

On Thu, Sep 8, 2011 at 10:11 AM, Ojan Vafai  wrote:

> On Thu, Sep 8, 2011 at 12:58 AM, Ryosuke Niwa  wrote:
>
>> On Thu, Sep 8, 2011 at 12:41 AM, Maciej Stachowiak  wrote:
>>>
>>> Do you have an idea for how to avoid needing to adjust the number of
>>> "../" path segments in the path to the harness? That's the most annoying
>>> step of the current copy/paste solution, and it does not seem like
>>> simplifying the boilerplate as you suggest resolves that issue.
>>>
>>
>> I personally don't think it be that annoying. Usually, I can find another
>> test that uses the same framework in the same depth.  I'd be more annoyed by
>> having to run a script on Terminal (and presumably giving it a relative path
>> from LayoutTests).
>>
>
> Like Ryosuke, I haven't found this to be much of a nuisance in practice
> with dump-as-markup.js since there's only one path you need to fix up.
>
___
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev


Re: [webkit-dev] make-script-test-wrappers not being maintained

2011-09-08 Thread Alexey Proskuryakov

08.09.2011, в 00:58, Ryosuke Niwa написал(а):

> I'd be more annoyed by having to run a script on Terminal (and presumably 
> giving it a relative path from LayoutTests).


FWIW, the new script supports other ways to provide the path:

make-new-script-test new-test.html (will create the test in current directory)
make-new-script-test fast/loader/new-test.html (a relative path is always from 
LayoutTests directory)
make-new-script-test /Volumes/Data/WebKit/LayoutTests/fast/loader/new-test.html

The last option might be best for someone who dislikes command line, as you can 
drag a folder to a Terminal window to get an absolute path, and just type in 
test name. The script will open the new test in your $EDITOR then if you have 
this environment variable set.

- WBR, Alexey Proskuryakov

___
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev


Re: [webkit-dev] make-script-test-wrappers not being maintained

2011-09-08 Thread Jarred Nicholls
On Thu, Sep 8, 2011 at 11:04 AM, Tom Zakrajsek  wrote:

> Wouldn't that make it so that the tests would *only* work in DRT?


Yeah that's not good ;)


>
>
>
> On 09/08/2011 07:58 AM, Eric Seidel wrote:
>
>> We could also teach DumpRenderTree to lie about what "/" is, so we
>> could include the scripts like this:
>>
>> 
>>
>> On Thu, Sep 8, 2011 at 1:14 AM, Adam Barth  wrote:
>>
>>> On Thu, Sep 8, 2011 at 12:41 AM, Maciej Stachowiak
>>>  wrote:
>>>
 Do you have an idea for how to avoid needing to adjust the number of
 "../"
 path segments in the path to the harness? That's the most annoying step
 of
 the current copy/paste solution, and it does not seem like simplifying
 the
 boilerplate as you suggest resolves that issue.

>>> One approach is to have an inline script that examines the URL and
>>> sets the base URL appropriately:
>>>
>>>