Bug 17685

Summary: CSS3 Selector Test: attribute selector failing to match empty string
Product: WebKit Reporter: Eric Seidel (no email) <eric>
Component: CSSAssignee: Robert Blaut <webkit>
Status: RESOLVED FIXED    
Severity: Normal CC: webkit
Priority: P2 Keywords: HasReduction
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.5   
URL: http://disruptive-innovations.com/zoo/css3tests/selectorTest.html#target
Attachments:
Description Flags
test case
none
patch for the bug eric: review+

Description Eric Seidel (no email) 2008-03-05 14:00:53 PST
CSS3 Selector Test: attribute selector failing to match empty string 

    .blox9[foo~=""] { background-color: red; }

<div class="blox9 unitTest" foo="" title="[~=] attribute selector looking for empty string in empty attribute"></div>
Comment 1 Robert Blaut 2008-03-05 15:20:27 PST
Created attachment 19559 [details]
test case
Comment 2 Robert Blaut 2008-03-23 13:14:07 PDT
Created attachment 19985 [details]
patch for the bug

Patch with test case for layout tests attached.
Comment 3 Eric Seidel (no email) 2008-03-23 13:29:56 PDT
Comment on attachment 19985 [details]
patch for the bug

Looks good to me.  I'll fix the comment when landing.

// The selector's value can't contain a space, neither can be empty, or it's totally bogus.

should be:

// Empty selectors or selectors containing spaces are bogus.
Comment 4 Eric Seidel (no email) 2008-03-23 14:09:46 PDT
r31238