Changeset 83333 in webkit


Ignore:
Timestamp:
Apr 8, 2011 1:14:54 PM (13 years ago)
Author:
Dimitri Glazkov
Message:

2011-04-08 Dominic Cooney <dominicc@google.com>

Reviewed by Adam Roben.

layoutTestController.shadowRoot returns null, not undefined, when
its argument is invalid.
https://bugs.webkit.org/show_bug.cgi?id=58121

Update the test to expect null and not undefined.

  • fast/dom/HTMLKeygenElement/keygen-expected.txt:
  • fast/dom/HTMLKeygenElement/keygen.html:
  • platform/chromium/test_expectations.txt: unskip keygen.html

2011-04-08 Dominic Cooney <dominicc@google.com>

Reviewed by Adam Roben.

Make layoutTestController.shadowRoot return null, not undefined,
when its argument is invalid.
https://bugs.webkit.org/show_bug.cgi?id=58121

  • WebCoreSupport/DumpRenderTreeSupportGtk.cpp: (DumpRenderTreeSupportGtk::shadowRoot):

2011-04-08 Dominic Cooney <dominicc@google.com>

Reviewed by Adam Roben.

Make layoutTestController.shadowRoot return null, not undefined,
when its argument is invalid.
https://bugs.webkit.org/show_bug.cgi?id=58121

  • DumpRenderTree/mac/LayoutTestControllerMac.mm: (LayoutTestController::shadowRoot):
  • WebKitTestRunner/InjectedBundle/LayoutTestController.cpp: (WTR::LayoutTestController::shadowRoot):
Location:
trunk
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r83328 r83333  
     12011-04-08  Dominic Cooney  <dominicc@google.com>
     2
     3        Reviewed by Adam Roben.
     4
     5        layoutTestController.shadowRoot returns null, not undefined, when
     6        its argument is invalid.
     7        https://bugs.webkit.org/show_bug.cgi?id=58121
     8
     9        Update the test to expect null and not undefined.
     10
     11        * fast/dom/HTMLKeygenElement/keygen-expected.txt:
     12        * fast/dom/HTMLKeygenElement/keygen.html:
     13        * platform/chromium/test_expectations.txt: unskip keygen.html
     14
    1152011-04-08  Ryosuke Niwa  <rniwa@webkit.org>
    216
  • trunk/LayoutTests/fast/dom/HTMLKeygenElement/keygen-expected.txt

    r83256 r83333  
    44PASS keygen.options is undefined
    55PASS shadow.firstChild.tagName is "SELECT"
    6 PASS layoutTestController.shadowRoot(shadow) is undefined
     6PASS layoutTestController.shadowRoot(shadow) is null
    77PASS layoutTestController.shadowRoot(shadow.firstChild) is null
    88PASS successfullyParsed is true
  • trunk/LayoutTests/fast/dom/HTMLKeygenElement/keygen.html

    r83256 r83333  
    1717  var shadow = layoutTestController.shadowRoot(keygen);
    1818  shouldBe('shadow.firstChild.tagName', '"SELECT"');
    19   shouldBe('layoutTestController.shadowRoot(shadow)', 'undefined');
     19  shouldBe('layoutTestController.shadowRoot(shadow)', 'null');
    2020  shouldBe('layoutTestController.shadowRoot(shadow.firstChild)', 'null');
    2121}
  • trunk/LayoutTests/platform/chromium/test_expectations.txt

    r83318 r83333  
    32463246BUGWK57259 : http/tests/misc/link-rel-icon-beforeload.html = FAIL PASS
    32473247
    3248 // Unskip when Chromium DRT layoutTestController implements shadowRoot accessor
    3249 BUGWK56573 : fast/dom/HTMLKeygenElement/keygen.html = FAIL
    3250 
    32513248// This test is very flaky on Mac and a little flaky on Win and Linux.
    32523249BUGXXX : media/video-delay-load-event.html = PASS TEXT
  • trunk/Source/WebKit/gtk/ChangeLog

    r83272 r83333  
     12011-04-08  Dominic Cooney  <dominicc@google.com>
     2
     3        Reviewed by Adam Roben.
     4
     5        Make layoutTestController.shadowRoot return null, not undefined,
     6        when its argument is invalid.
     7        https://bugs.webkit.org/show_bug.cgi?id=58121
     8
     9        * WebCoreSupport/DumpRenderTreeSupportGtk.cpp:
     10        (DumpRenderTreeSupportGtk::shadowRoot):
     11
    1122011-04-08  Dominic Cooney  <dominicc@google.com>
    213
  • trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.cpp

    r83272 r83333  
    644644    Element* element = toElement(toJS(exec, value));
    645645    if (!element)
    646         return JSValueMakeUndefined(context);
     646        return JSValueMakeNull(context);
    647647
    648648    return toRef(exec, toJS(exec, element->shadowRoot()));
  • trunk/Tools/ChangeLog

    r83330 r83333  
     12011-04-08  Dominic Cooney  <dominicc@google.com>
     2
     3        Reviewed by Adam Roben.
     4
     5        Make layoutTestController.shadowRoot return null, not undefined,
     6        when its argument is invalid.
     7        https://bugs.webkit.org/show_bug.cgi?id=58121
     8
     9        * DumpRenderTree/mac/LayoutTestControllerMac.mm:
     10        (LayoutTestController::shadowRoot):
     11        * WebKitTestRunner/InjectedBundle/LayoutTestController.cpp:
     12        (WTR::LayoutTestController::shadowRoot):
     13
    1142011-04-08  Dirk Pranke  <dpranke@chromium.org>
    215
  • trunk/Tools/DumpRenderTree/mac/LayoutTestControllerMac.mm

    r82536 r83333  
    10731073    DOMElement *element = [DOMElement _DOMElementFromJSContext:context value:jsElement];
    10741074    if (!element)
    1075         return JSValueMakeUndefined(context);
     1075        return JSValueMakeNull(context);
    10761076    return [element _shadowRoot:context];
    10771077}
  • trunk/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp

    r83270 r83333  
    361361
    362362    if (!element || !JSValueIsObject(context, element))
    363         return JSValueMakeUndefined(context);
     363        return JSValueMakeNull(context);
    364364
    365365    WKRetainPtr<WKBundleNodeHandleRef> domElement = adoptWK(WKBundleNodeHandleCreate(context, const_cast<JSObjectRef>(element)));
    366366    if (!domElement)
    367         return JSValueMakeUndefined(context);
     367        return JSValueMakeNull(context);
    368368
    369369    WKRetainPtr<WKBundleNodeHandleRef> shadowRootDOMElement = adoptWK(WKBundleNodeHandleCopyElementShadowRoot(domElement.get()));
Note: See TracChangeset for help on using the changeset viewer.