gecko/dom/tests/mochitest/general/test_interfaces.html
Ms2ger a75666050c Bug 847195 - Make NamedNodeMap only deal with Attrs; r=khuey
--HG--
rename : dom/interfaces/core/nsIDOMNamedNodeMap.idl => dom/interfaces/core/nsIDOMMozNamedAttrMap.idl
2013-03-10 09:00:33 +01:00

559 lines
13 KiB
HTML

<!DOCTYPE HTML>
<html>
<!--
https://bugzilla.mozilla.org/show_bug.cgi?id=766694
-->
<head>
<meta charset="utf-8">
<title>Test for Bug 766694</title>
<script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
</head>
<body>
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=766694">Mozilla Bug 766694</a>
<p id="display"></p>
<div id="content" style="display: none">
</div>
<pre id="test">
<script type="application/javascript">
/** Test for Bug 766694 **/
var interfaceNamesInGlobalScope =
[
"MozApplicationEvent",
"HTMLByteRanges",
"URL",
"BatteryManager",
"HTMLStyleElement",
"PropertyNodeList",
"SVGPatternElement",
"LinkStyle",
"IDBTransaction",
"CSSMediaRule",
"SVGFEMergeNodeElement",
"HTMLUnknownElement",
"SVGStylable",
"MozContactChangeEvent",
"ToString",
"MozBrowserFrame",
"UserDataHandler",
"HTMLDirectoryElement",
"SVGNumberList",
"SVGMaskElement",
"DeviceMotionEvent",
"GetSVGDocument",
"SVGAnimatedPreserveAspectRatio",
"MozSmsRequest",
"SVGViewElement",
"HTMLTableSectionElement",
"HTMLCollection",
"HTMLProgressElement",
"CRMFObject",
"CSSStyleSheet",
"UIEvent",
"IDBOpenDBRequest",
"XMLHttpRequest",
"SVGTextPathElement",
"StorageItem",
"SVGPolygonElement",
"MutationRecord",
"TimeEvent",
"HTMLElement",
"HTMLOptionElement",
"Pkcs11",
"NotifyAudioAvailableEvent",
"ElementReplaceEvent",
"Array",
"SVGZoomAndPan",
"XULPopupElement",
"MediaError",
"DeviceStorageCursor",
"DeviceStorageChangeEvent",
"PageTransitionEvent",
"DataContainerEvent",
"MozCSSKeyframesRule",
"SVGAnimatedInteger",
"TouchEvent",
"OpenWindowEventDetail",
"IDBIndex",
"EventListener",
"TransitionEvent",
"XULContainerItemElement",
"HTMLTableCaptionElement",
"SVGRect",
"IDBCursor",
"History",
"HTMLTableRowElement",
"NodeFilter",
"ClientRectList",
"CanvasRenderingContext2D",
"SVGPathSegLinetoVerticalRel",
"MozAlarmsManager",
"MozPowerManager",
"SVGElement",
"GeoPositionError",
"XPathEvaluator",
"NodeIterator",
"MozNavigatorNetwork",
"CryptoDialogs",
"SVGLocatable",
"XULElement",
"CSSRuleList",
"SVGMarkerElement",
"Rect",
"SVGPathElement",
"SVGUseElement",
"SVGAnimatedPoints",
"DeviceAcceleration",
"DOMError",
"SVGAnimateMotionElement",
"HTMLMeterElement",
"SmartCardEvent",
"CSSValueList",
"ValidityState",
"HTMLAppletElement",
"Touch",
"Controllers",
"AnimationEvent",
"NavigatorDesktopNotification",
"LoadStatus",
"MediaQueryList",
"Contact",
"MediaQueryListListener",
"DesktopNotificationCenter",
"PluginArray",
"XULSelectControlElement",
"TimeRanges",
"ImageData",
"SVGPathSegArcAbs",
"MimeTypeArray",
"DocumentFragment",
"ParserJS",
"CanvasPattern",
"GeoPosition",
"XPathExpression",
"BarProp",
"NSEditableElement",
"SVGRectElement",
"DOMRequest",
"WindowPerformance",
"DOMSettableTokenList",
"SVGTransformList",
"SVGTransformable",
"XULControlElement",
"HTMLFrameSetElement",
"CSSCharsetRule",
"TouchList",
"DOMStringList",
"HTMLCommandElement",
"FileList",
"XULRelatedElement",
"Blob",
"Node",
"HTMLEmbedElement",
"ProgressEvent",
"SVGAnimateElement",
"MutationEvent",
"TreeSelection",
"DeviceLightEvent",
"SVGCircleElement",
"SVGFEComponentTransferElement",
"SVGPathSeg",
"SVGSVGElement",
"GlobalPropertyInitializer",
"HTMLMenuItemElement",
"HTMLDataListElement",
"XPathResult",
"XMLDocument",
"DocumentType",
"MozNamedAttrMap",
"DeviceProximityEvent",
"XULLabeledControlElement",
"MozWakeLock",
"MozConnection",
"WebGLRenderingContext",
"JSON",
"ClientRect",
"GetUserMediaSuccessCallback",
"CommandEvent",
"HTMLDocument",
"DeviceOrientationEvent",
"HTMLPreElement",
"StorageEvent",
"CSS2Properties",
"StorageIndexedDB",
"XULDocument",
"XULMultiSelectControlElement",
"SVGTitleElement",
"ContactProperties",
"PerformanceTiming",
"LSProgressEvent",
"NSEvent",
"HTMLBRElement",
"MouseScrollEvent",
"WheelEvent",
"HashChangeEvent",
"TreeWalker",
"HTMLTitleElement",
"LockedFile",
"GetUserMediaErrorCallback",
"SVGFEMorphologyElement",
"SVGFETurbulenceElement",
"XULTextBoxElement",
"SVGDocument",
"CSSStyleDeclaration",
"SVGAltGlyphElement",
"Screen",
"FileReader",
"SVGSwitchElement",
"SVGPolylineElement",
"SVGPathSegLinetoAbs",
"NavigatorDeviceStorage",
"HTMLOptionsCollection",
"IDBKeyRange",
"Parser",
"HTMLDivElement",
"HTMLLinkElement",
"ClientInformation",
"SVGMpathElement",
"HTMLTextAreaElement",
"SVGAnimatedEnumeration",
"Attr",
"StyleSheet",
"HTMLBodyElement",
"SVGPathSegCurvetoQuadraticSmoothRel",
"HTMLHeadingElement",
"Document",
"FileHandle",
"HTMLAnchorElement",
"SVGZoomEvent",
"UserProximityEvent",
"SVGAnimateTransformElement",
"CSSMozDocumentRule",
"HTMLQuoteElement",
"PopStateEvent",
"IDBVersionChangeEvent",
"HTMLCanvasElement",
"MouseEvent",
"OfflineResourceList",
"ContactAddress",
"Range",
"MozCSSKeyframeRule",
"SettingsLock",
"Screen",
"ImageDocument",
"TextMetrics",
"SVGScriptElement",
"CDATASection",
"CanvasGradient",
"SVGViewSpec",
"DOMException",
"MozSmsMessage",
"SVGFESpecularLightingElement",
"StorageObsolete",
"ContactManager",
"NSXPathExpression",
"SVGLineElement",
"SVGPathSegArcRel",
"XSLTProcessor",
"SVGPathSegLinetoVerticalAbs",
"SVGPathSegLinetoRel",
"HTMLImageElement",
"MozSmsEvent",
"CustomEvent",
"XMLHttpRequestUpload",
"SVGFEFuncBElement",
"Text",
"SVGPathSegCurvetoCubicRel",
"DataTransfer",
"SVGTSpanElement",
"SVGRadialGradientElement",
"SVGFEDisplacementMapElement",
"SVGPathSegCurvetoCubicSmoothAbs",
"CSSValue",
"DesktopNotification",
"KeyEvent",
"HTMLAreaElement",
"XULLabelElement",
"FormData",
"IDBDatabase",
"CSSPrimitiveValue",
"SVGStopElement",
"XULCommandEvent",
"HTMLMediaElement",
"SVGPathSegLinetoHorizontalAbs",
"SVGAnimatedRect",
"SVGTextContentElement",
"TreeColumn",
"XPathNamespace",
"FontFace",
"SVGPathSegCurvetoCubicSmoothRel",
"HTMLMapElement",
"SVGImageElement",
"HTMLMetaElement",
"NotifyPaintEvent",
"XULTreeElement",
"DragEvent",
"IDBObjectStore",
"NodeSelector",
"NavigatorUserMedia",
"TreeContentView",
"MimeType",
"SVGForeignObjectElement",
"MozMobileNetworkInfo",
"SVGAnimatedString",
"HTMLPropertiesCollection",
"WindowInternal",
"Serializer",
"SVGFEFuncGElement",
"XULCheckboxElement",
"SVGFEPointLightElement",
"ModalContentWindow",
"Crypto",
"StorageManager",
"SVGAngle",
"Navigator",
"SVGPathSegCurvetoQuadraticSmoothAbs",
"HTMLButtonElement",
"SVGPointList",
"SVGFEColorMatrixElement",
"USSDReceivedEvent",
"SettingsManager",
"DeviceRotationRate",
"HTMLAudioElement",
"SVGFEDistantLightElement",
"HTMLOListElement",
"ProcessingInstruction",
"CSSUnknownRule",
"SVGComponentTransferFunctionElement",
"SVGEvent",
"SVGPathSegLinetoHorizontalRel",
"SVGAnimatedNumber",
"HTMLHtmlElement",
"MozSmsManager",
"MozSmsFilter",
"SVGFETileElement",
"MozMobileConnectionInfo",
"CSSRule",
"HTMLSelectElement",
"MessageEvent",
"SVGFEImageElement",
"URL",
"DeviceStorage",
"SVGFEOffsetElement",
"DOMImplementation",
"SVGFECompositeElement",
"MediaList",
"HTMLFrameElement",
"NodeList",
"SVGPathSegCurvetoQuadraticRel",
"IDBFactory",
"SVGFilterPrimitiveStandardAttributes",
"CSSImportRule",
"SVGPathSegClosePath",
"HTMLTableCellElement",
"WindowUtils",
"SVGAnimatedNumberList",
"WindowCollection",
"SVGPathSegMovetoRel",
"ChromeWindow",
"Comment",
"HTMLSourceElement",
"SVGStringList",
"Storage",
"HTMLModElement",
"PaintRequest",
"XPathNSResolver",
"XULDescriptionElement",
"SVGLinearGradientElement",
"JSWindow",
"SVGGElement",
"BoxObject",
"SVGFEBlendElement",
"Event",
"File",
"HTMLOptGroupElement",
"SVGAnimatedLengthList",
"SVGAnimatedTransformList",
"MozTouchEvent",
"MozWakeLockListener",
"Selection",
"XULTreeBuilder",
"ScrollAreaEvent",
"SVGStyleElement",
"XULContainerElement",
"DOMTokenList",
"HTMLHRElement",
"HTMLFontElement",
"SVGFEFloodElement",
"HTMLDListElement",
"SVGSymbolElement",
"SVGLengthList",
"TreeColumns",
"PaintRequestList",
"SVGTextElement",
"SimpleGestureEvent",
"SVGMatrix",
"HTMLUListElement",
"SVGFEConvolveMatrixElement",
"SVGAnimationElement",
"SVGMetadataElement",
"EventListenerInfo",
"CSSStyleRule",
"IDBRequest",
"Performance",
"XULMenuListElement",
"SVGTransform",
"SVGTextPositioningElement",
"ContactFindSortOptions",
"ContactFindOptions",
"SVGFEMergeElement",
"FileRequest",
"SVGDefsElement",
"Element",
"HTMLBaseElement",
"GeoPositionErrorCallback",
"HTMLVideoElement",
"MozSettingsEvent",
"SVGAnimatedPathData",
"SVGUnitTypes",
"SVGTests",
"RGBColor",
"HTMLLabelElement",
"MozSmsCursor",
"EventSource",
"MozNavigatorSms",
"SVGSetElement",
"GlobalObjectConstructor",
"SVGAnimatedBoolean",
"HTMLTableElement",
"Window",
"SVGNumber",
"XULImageElement",
"Plugin",
"SVGAnimatedLength",
"FontFaceList",
"EventTarget",
"SVGFEFuncRElement",
"SVGPathSegMovetoAbs",
"SVGPoint",
"GeoPositionCoords",
"HTMLIFrameElement",
"PerformanceNavigation",
"MediaStream",
"DOMStringMap",
"HTMLFieldSetElement",
"SVGFEDiffuseLightingElement",
"StyleSheetList",
"ElementCSSInlineStyle",
"HTMLInputElement",
"CharacterData",
"HTMLObjectElement",
"SVGURIReference",
"GeoGeolocation",
"HTMLParamElement",
"HTMLTableColElement",
"MozBlobBuilder",
"SVGFESpotLightElement",
"PopupBlockedEvent",
"XULButtonElement",
"CSSPageRule",
"Location",
"DocumentXBL",
"HTMLHeadElement",
"XULTemplateBuilder",
"GeoPositionCallback",
"XULCommandDispatcher",
"DocumentTouch",
"XULSelectControlItemElement",
"SVGPathSegCurvetoQuadraticAbs",
"MutationObserver",
"RequestService",
"Counter",
"SVGAnimatedAngle",
"SVGPathSegList",
"SVGFEFuncAElement",
"WebSocket",
"ElementTimeControl",
"HTMLLegendElement",
"SVGFEGaussianBlurElement",
"SVGEllipseElement",
"SVGDescElement",
"BeforeUnloadEvent",
"NSRGBAColor",
"MozBrowserFrame",
"SVGPreserveAspectRatio",
"HTMLMenuElement",
"CloseEvent",
"IDBCursorWithValue",
"CSSFontFaceRule",
"XMLHttpRequestEventTarget",
"CompositionEvent",
"HTMLOutputElement",
"HTMLFormElement",
"SVGLength",
"SVGFilterElement",
"HTMLScriptElement",
"SVGPathSegCurvetoCubicAbs",
"HTMLLIElement",
"SVGClipPathElement",
"NavigatorGeolocation",
"HTMLParagraphElement",
"EventTarget",
"File",
"SVGGradientElement",
"ContactTelField",
"ContactField",
"SVGFitToViewBox",
"SVGAElement",
"NavigatorCamera",
"CameraControl",
"CameraCapabilities",
"CameraManager",
"CSSSupportsRule",
"MozMobileCellInfo",
"UndoManager",
"DOMTransactionEvent",
"MozCanvasPrintState",
"TCPSocket",
"MozTimeManager",
"MozNavigatorTime",
"PermissionSettings",
"DataErrorEvent",
"DataChannel",
"MozNetworkStatsManager",
"MozNetworkStats",
"MozNetworkStatsData",
"RTCSessionDescription",
"RTCIceCandidate",
"RTCPeerConnection",
"LocalMediaStream",
"CSSConditionRule",
"CSSGroupingRule",
"AsyncScrollEventDetail",
"MozSmsSegmentInfo",
"DOMCursor",
"BlobEvent"
]
for (var i in SpecialPowers.Components.interfaces) {
var s = i.toString();
var name = null;
if (s.indexOf("nsIDOM") == 0) {
name = s.substring("nsIDOM".length);
} else if (s.indexOf("nsI") == 0) {
name = s.substring("nsI".length);
}
if (name && (name in window)) {
ok(interfaceNamesInGlobalScope.indexOf(name) >= 0,
"Unexpected interface name in global scope: " + name);
}
}
</script>
</pre>
</body>
</html>