Use new idlharness.js capability in interfaces.html
authorAryeh Gregor <AryehGregor+gitcommit@gmail.com>
Wed, 16 Nov 2011 13:56:08 -0700
changeset 678 91a2c1c3f552
parent 677 eccd9a0d408e
child 679 d278ee615900
Use new idlharness.js capability in interfaces.html
selecttest/interfaces.html
--- a/selecttest/interfaces.html	Wed Nov 16 12:38:09 2011 -0700
+++ b/selecttest/interfaces.html	Wed Nov 16 13:56:08 2011 -0700
@@ -8,7 +8,7 @@
 <script>
 "use strict";
 
-new IdlInterface('interface Selection {\n\
+var selectionInterface = new IdlInterface('interface Selection {\n\
   readonly attribute Node? anchorNode;\n\
   readonly attribute unsigned long anchorOffset;\n\
   readonly attribute Node? focusNode;\n\
@@ -32,5 +32,9 @@
   void               removeAllRanges();\n\
 \n\
   stringifier;\n\
-};').test();
+};');
+
+selectionInterface.test();
+selectionInterface.test_primary_interface_of(getSelection(), "getSelection()");
+selectionInterface.test_primary_interface_of(document.getSelection(), "document.getSelection()");
 </script>