Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(15)

Unified Diff: LayoutTests/dom/xhtml/level3/core/nodelookupnamespaceuri16.js

Issue 740223003: Revive tests for Document.createAttributeNS() and Element.setAttributeNodeNS() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: deprecation messages Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/dom/xhtml/level3/core/nodelookupnamespaceuri16.js
diff --git a/LayoutTests/dom/xhtml/level3/core/nodelookupnamespaceuri06.js b/LayoutTests/dom/xhtml/level3/core/nodelookupnamespaceuri16.js
similarity index 79%
copy from LayoutTests/dom/xhtml/level3/core/nodelookupnamespaceuri06.js
copy to LayoutTests/dom/xhtml/level3/core/nodelookupnamespaceuri16.js
index 950ad7a235ccdf339da9041b268426348b391c5c..bb8131084fc291bfd6b70cecab890da468f0bf47 100644
--- a/LayoutTests/dom/xhtml/level3/core/nodelookupnamespaceuri06.js
+++ b/LayoutTests/dom/xhtml/level3/core/nodelookupnamespaceuri16.js
@@ -17,7 +17,7 @@ the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* @return uri identifier of test
*/
function getTargetURI() {
- return "http://www.w3.org/2001/DOM-Test-Suite/level3/core/nodelookupnamespaceuri06";
+ return "http://www.w3.org/2001/DOM-Test-Suite/level3/core/nodelookupnamespaceuri16";
}
var docsLoaded = -1000000;
@@ -76,20 +76,20 @@ function loadComplete() {
/**
*
- Invoke lookupNamespaceURI on an Element node with no prefix, which has a namespace
- attribute declaration with a namespace prefix and check if the value of the namespaceURI
- returned by using its prefix as a parameter is valid.
+ Invoke lookupNamespaceURI on a new Attribute node with with a namespace URI
+ and prefix and verify if the namespaceURI returned is null.
* @author IBM
* @author Neil Delima
* @see http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core#Node3-lookupNamespaceURI
*/
-function nodelookupnamespaceuri06() {
+function nodelookupnamespaceuri16() {
var success;
- if(checkInitialization(builder, "nodelookupnamespaceuri06") != null) return;
+ if(checkInitialization(builder, "nodelookupnamespaceuri16") != null) return;
var doc;
var elem;
- var elemList;
+ var attr;
+ var attNode;
var namespaceURI;
var docRef = null;
@@ -97,16 +97,17 @@ function nodelookupnamespaceuri06() {
docRef = this.doc;
}
doc = load(docRef, "doc", "hc_staff");
- elemList = doc.getElementsByTagName("p");
- elem = elemList.item(2);
- namespaceURI = elem.lookupNamespaceURI("dmstc");
- assertEquals("nodelookupnamespaceuri06","http://www.netzero.com",namespaceURI);
-
+ elem = doc.createElementNS("http://www.w3.org/1999/xhtml","dom3:p");
+ attr = doc.createAttributeNS("http://www.w3.org/XML/1998/namespace","xml:lang");
+ attNode = elem.setAttributeNodeNS(attr);
+ namespaceURI = attr.lookupNamespaceURI("xml");
+ assertNull("nodelookupnamespaceuri16",namespaceURI);
+
}
function runTest() {
- nodelookupnamespaceuri06();
+ nodelookupnamespaceuri16();
}

Powered by Google App Engine
This is Rietveld 408576698