blob: d9cf90725d4cf98dc98a44ea60e94173f48283a7 [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
* @description Attributes on </p>
import "dart:html";
import "../../testharness.dart";
import "../../../Utils/expect.dart";
const String htmlEL1 = r'''
p { background:lime; width:10em; height:10em; }
.fail { background:red; }
const String htmlEL2 = r'''
There should be a green square and no red below: </p class=fail>
void main() {
document.head.appendHtml(htmlEL1, treeSanitizer: new NullTreeSanitizer());
document.body.appendHtml(htmlEL2, treeSanitizer: new NullTreeSanitizer());
var elm = document.getElementsByTagName("p")[0];
Expect.notEquals("fail", elm.className);
document.body.appendHtml("PASS", treeSanitizer: new NullTreeSanitizer());