Bug 29798

Summary: Move message-port-multi.js from resources to script-tests
Product: WebKit Reporter: Shinichiro Hamaji <hamaji>
Component: Tools / TestsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: atwilson, commit-queue, eric
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: OS X 10.5   
Attachments:
Description Flags
Patch v1
none
Revert patch v1
none
Revert patch v2
none
Revert patch v3 none

Description Shinichiro Hamaji 2009-09-28 00:42:11 PDT
While I was working for Bug 25880, some tests which weren't generated from TEMPLATE.html were added into resources directories.

fast/js/resources/getOwnPropertyDescriptor.js
fast/backgrounds/repeat/resources/margin-shorthand.js
fast/events/resources/message-port-multi.js

The fist two JS requires custom HTMLs so that we don't need to move them (they should have been added in exception lists of make-script-tests-wrappers). It seems we may want to move the last JS into script-tests directory.
Comment 1 Shinichiro Hamaji 2009-09-28 00:44:53 PDT
Created attachment 40220 [details]
Patch v1
Comment 2 WebKit Commit Bot 2009-09-28 11:51:20 PDT
Comment on attachment 40220 [details]
Patch v1

Clearing flags on attachment: 40220

Committed r48823: <http://trac.webkit.org/changeset/48823>
Comment 3 WebKit Commit Bot 2009-09-28 11:51:26 PDT
All reviewed patches have been landed.  Closing bug.
Comment 4 Andrew Wilson 2009-09-29 10:27:23 PDT
This test contains asynchronous tests, so including js-test-post.js is incorrect.

Note that if you look at the test expections, it inserts "TEST COMPLETE" in the middle of the test output, which is not correct.
Comment 5 Shinichiro Hamaji 2009-09-29 10:31:34 PDT
(In reply to comment #4)
> This test contains asynchronous tests, so including js-test-post.js is
> incorrect.
> 
> Note that if you look at the test expections, it inserts "TEST COMPLETE" in the
> middle of the test output, which is not correct.

I see. So, we can just revert my patch?
Comment 6 Eric Seidel (no email) 2009-09-29 10:33:16 PDT
Yes, it's a known issue that the js testing framework stuff doesn't handle async tests well.  I thought I filed a bug about this a while back.  Basically we'd like to eventually add an "imDone()" method of some sort that would print the TEST COMPLETED stuff for you.  Many tests have already "hacked" this by removing js-test-post.js and done their own TEST COMPLETED writing.  Eventually we should just make this function part of js-test-pre.js and have js-test-post call it when the test is a waitUntilDone() test.
Comment 7 Andrew Wilson 2009-09-29 10:35:57 PDT
It sounds like you were trying to get this test to be generated from
TEMPLATE.html, but it's probably not appropriate for this test since it doesn't
follow the standard form.

I don't actually understand what the motivation behind the test was - if it was
just an attempt at cleanup, then yeah, I'd revert it.
Comment 8 Shinichiro Hamaji 2009-09-29 10:38:47 PDT
Created attachment 40309 [details]
Revert patch v1
Comment 9 Eric Seidel (no email) 2009-09-29 14:07:01 PDT
I think we're trying to slowly improve the "standard form" over time.  The original dream of all the .js tests was that we wouldn't check in the .html files at all.  I'm not sure we'll ever reach that dream though.  Definitely js-test-pre.js and js-test-post.js need losts of love to support more types of testing (like async tests, XHTML tests, SVG tests, etc.)
Comment 10 Shinichiro Hamaji 2009-09-29 22:02:42 PDT
Created attachment 40342 [details]
Revert patch v2
Comment 11 Shinichiro Hamaji 2009-09-29 22:04:04 PDT
(In reply to comment #10)
> Created an attachment (id=40342) [details]
> Revert patch v2

I've updated the revert patch so it has a comment to mention we don't use js-test-post.

Sorry for confusion by this bug.
Comment 12 WebKit Commit Bot 2009-09-29 22:58:57 PDT
Comment on attachment 40342 [details]
Revert patch v2

Rejecting patch 40342 from commit-queue.

Failed to run "['WebKitTools/Scripts/run-webkit-tests', '--no-launch-safari', '--quiet', '--exit-after-n-failures=1']" exit_code: 1
Running build-dumprendertree
Running tests from /Users/eseidel/Projects/CommitQueue/LayoutTests
Testing 11355 test cases.
fast/events/message-port-multi.html -> failed

Exiting early after 1 failures. 6051 tests run.
110.37s total testing time

6050 test cases (99%) succeeded
1 test case (<1%) had incorrect layout
2 test cases (<1%) had stderr output
Comment 13 Shinichiro Hamaji 2009-09-29 23:23:28 PDT
Created attachment 40346 [details]
Revert patch v3
Comment 14 Shinichiro Hamaji 2009-09-29 23:24:54 PDT
(In reply to comment #13)
> Created an attachment (id=40346) [details]
> Revert patch v3

Sorry, I used patch -R and resources/*.js wasn't tracked by git. I created the patch again using git mv.
Comment 15 WebKit Commit Bot 2009-09-30 05:02:07 PDT
Comment on attachment 40346 [details]
Revert patch v3

Clearing flags on attachment: 40346

Committed r48926: <http://trac.webkit.org/changeset/48926>
Comment 16 WebKit Commit Bot 2009-09-30 05:02:11 PDT
All reviewed patches have been landed.  Closing bug.