blob: f6a4f5d4087fdd889d4f752232d25ffd4764f09f [file] [log] [blame]
// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
/// @assertion void appendHtml(String text)
/// Parses the specified text as HTML and adds the resulting node after the
/// last child of this element.
/// @description Checks that new node will be added after the
/// last child of this element.
/// @issue 43315
import "dart:html";
import "../../../Utils/expect.dart";
main() {
IFrameElement x = new IFrameElement();
x.appendHtml('text', treeSanitizer: NodeTreeSanitizer.trusted);
Expect.isTrue(x.firstChild is Text, 'append to empty children list');
x = new IFrameElement();
x.appendHtml('<div></div>', treeSanitizer: NodeTreeSanitizer.trusted);
Expect.isTrue(x.firstChild is CharacterData);