Commit 4ece216f authored by Rune Lillesveen's avatar Rune Lillesveen Committed by Commit Bot

Missing call to base's FinishedParsingChildren in datalist.

Bug: 990767
Change-Id: I7040082705506dda5acc5c27e80d8a25822b3e2e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1738548Reviewed-by: default avatarMason Freed <masonfreed@chromium.org>
Commit-Queue: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#684369}
parent ae662c25
......@@ -1236,6 +1236,7 @@ jumbo_source_set("unit_tests") {
"html/forms/file_input_type_test.cc",
"html/forms/form_controller_test.cc",
"html/forms/form_data_test.cc",
"html/forms/html_data_list_element_test.cc",
"html/forms/html_form_control_element_test.cc",
"html/forms/html_form_element_test.cc",
"html/forms/html_input_element_test.cc",
......
......@@ -58,6 +58,7 @@ void HTMLDataListElement::ChildrenChanged(const ChildrenChange& change) {
}
void HTMLDataListElement::FinishParsingChildren() {
HTMLElement::FinishParsingChildren();
GetTreeScope().GetIdTargetObserverRegistry().NotifyObservers(
GetIdAttribute());
}
......
// Copyright 2019 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "third_party/blink/renderer/core/html/forms/html_data_list_element.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/renderer/core/dom/document.h"
#include "third_party/blink/renderer/core/testing/sim/sim_request.h"
#include "third_party/blink/renderer/core/testing/sim/sim_test.h"
namespace blink {
class HTMLDataListElementTest : public SimTest {};
TEST_F(HTMLDataListElementTest, FinishedParsingChildren) {
SimRequest main_resource("https://example.com/", "text/html");
LoadURL("https://example.com/");
main_resource.Complete("<datalist id=list></datalist>");
auto* data_list = GetDocument().getElementById("list");
ASSERT_TRUE(data_list);
EXPECT_TRUE(data_list->IsFinishedParsingChildren());
}
} // namespace blink
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment