Bug 63921 - keyPath of createIndex() must not be nullable
Summary: keyPath of createIndex() must not be nullable
Status: CLOSED INVALID
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-04 18:41 PDT by Kentaro Hara
Modified: 2011-07-06 17:11 PDT (History)
6 users (show)

See Also:


Attachments
Patch (4.35 KB, patch)
2011-07-04 18:52 PDT, Kentaro Hara
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kentaro Hara 2011-07-04 18:41:02 PDT
keyPath of createIndex() must not be nullable (http://dvcs.w3.org/hg/IndexedDB/raw-file/tip/Overview.html#widl-IDBObjectStore-createIndex-IDBIndex-DOMString-name-DOMString-keyPath-Object-optionalParameters). However, LayoutTests/storage/indexeddb/mozilla/create-index-null-name.html is trying to test that null is accepted as the keyPath of createIndex().
Comment 1 Kentaro Hara 2011-07-04 18:52:20 PDT
Created attachment 99663 [details]
Patch
Comment 2 Alexey Proskuryakov 2011-07-05 00:08:40 PDT
If WebKit behavior is incorrect, then it should be fixed, and regression test should be corrected to test for proper behavior. How does removing a test help?
Comment 3 Kentaro Hara 2011-07-05 00:27:45 PDT
> If WebKit behavior is incorrect, then it should be fixed, and regression test should be corrected to test for proper behavior. How does removing a test help?

I am trying to fix a keypath parser in WebKit bug 62288, and then found that storage/indexeddb/mozilla/create-index-null-name.html fails with my patch. So I thought that we should first remove the test (because the test is against the spec) as another bug. If you think that I should remove the test in bug 62288, I would like to just close this bug and do it in bug 62288.
Comment 4 Alexey Proskuryakov 2011-07-05 00:34:02 PDT
Yes, we regularly make changes to code and tests in the same patch. That minimizes confusion when looking at the changes later (for example to study them, to revert or to merge on a branch).
Comment 5 Tony Chang 2011-07-06 10:00:25 PDT
In addition to keeping the test changes with the code changes, can we update the test to reflect the correct behavior rather than removing it completely?
Comment 6 Alexey Proskuryakov 2011-07-06 10:08:21 PDT
> I would like to just close this bug and do it in bug 62288.

So, let's do that.
Comment 7 Kentaro Hara 2011-07-06 17:11:11 PDT
(In reply to comment #5)
> In addition to keeping the test changes with the code changes, can we update the test to reflect the correct behavior rather than removing it completely?

Yes, I am doing this in bug 62288. In bug 62288, I removed create-index-null-name.html and instead added the test that reflects the correct behavior to keypath-basics.html. 

Closing this bug.