test(function() {
assert_true("querySelector" in document,document.title);
});
- </script>
+ </script>
</body>
</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_document_queryselector_no_argument</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if document.querySelector() method without arguments that must excepting TypeError exception is to be thrown" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ try {
+ var sel = document.querySelector();
+ assert_true(false, "it should throw exception");
+ }
+ catch (e) {
+ assert_true(e.message == "Not enough arguments", "TypeError exception is to be thrown");
+ }
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_document_queryselector_return_null</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if document.querySelector() method return null if there is no matching Element" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ assert_equals(document.querySelector("input"), null, "The return value");
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_document_queryselector_type</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if document.querySelector() method is of type function" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ assert_equals((typeof document.querySelector), "function", "The type of document.queryselector");
+ }, document.title);
+ </script>
+ </body>
+</html>
test(function() {
assert_true("querySelectorAll" in document,document.title);
});
- </script>
+ </script>
</body>
</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_document_queryselectorall_no_argument</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if document.querySelectorAll() method without arguments that must excepting TypeError exception is to be thrown" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ try {
+ var sel = document.querySelectorAll();
+ assert_true(false, "It should throw exception");
+ }
+ catch (e) {
+ assert_true(e.message == "Not enough arguments", "TypeError exception is to be thrown");
+ }
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_document_queryselectorall_return_nodelist</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if document.querySelectorAll() method return a NodeList containing all of the matching Element nodes within the subtrees of the context node" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <form>
+ <input id="txt1" class="txtclass" type="text" />
+ </form>
+ <script>
+ test(function () {
+ assert_equals(document.querySelectorAll(".txtclass").toString(), "[object NodeList]", "The return type");
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_document_queryselectorall_type</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if document.querySelectorAll() method is of type function" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function() {
+ assert_equals(typeof document.querySelectorAll, "function", "the type of document.queryselectorall");
+ }, document.title);
+ </script>
+ </body>
+</html>
var frag = document.createDocumentFragment();
assert_true("querySelector" in frag,document.title);
});
- </script>
+ </script>
</body>
</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_documentfragment_queryselector_no_argument</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if DocumentFragment.querySelector() method without arguments that must excepting TypeError exception is to be thrown" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ var docfrag = document.createDocumentFragment();
+ try {
+ var sel = docfrag.querySelector();
+ assert_true(false, "it should throw exception");
+ }
+ catch (e) {
+ assert_true(e.message == "Not enough arguments", "TypeError exception is to be thrown");
+ }
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_documentfragment_queryselector_return_first</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if DocumentFragment.querySelector() method must return the first matching Element node within the subtrees of the context node" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ var docfrag = document.createDocumentFragment();
+ for (var i = 0; i < 3; i++) {
+ var div = document.createElement("div");
+ div.id = "div" + (i + 1).toString();
+ div.className = "divcalss";
+ docfrag.appendChild(div);
+ }
+ assert_equals(docfrag.querySelector("#div1,#div2").id, "div1", "the docfrag.querySelector value");
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_documentfragment_queryselector_type</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if DocumentFragment.querySelector() method is of type function" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ var frag = document.createDocumentFragment();
+ assert_equals(typeof frag.querySelector, "function", "The type of documentfragment.queryselector");
+ }, document.title);
+ </script>
+ </body>
+</html>
var frag = document.createDocumentFragment();
assert_true("querySelectorAll" in frag,document.title);
});
- </script>
+ </script>
</body>
</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_documentfragment_queryselectorall_no_argument</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if DocumentFragment.querySelectorAll() method without arguments that must excepting TypeError exception is to be thrown" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ var docfrag = document.createDocumentFragment();
+ try {
+ var sel = docfrag.querySelectorAll();
+ assert_true(false, "it should throw an exception");
+ }
+ catch (e) {
+ assert_true(e.message == "Not enough arguments", "TypeError exception is to be thrown");
+ }
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_documentfragment_queryselectorall_return_nodelist</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if DocumentFragment.querySelectorAll() method return a NodeList containing all of the matching Element nodes within the subtrees of the context node, in document order" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ var docfrag = document.createDocumentFragment();
+ assert_equals(docfrag.querySelectorAll("div").toString(), "[object NodeList]", "the return type of documentfragment.querySelectorAll");
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_documentfragment_queryselectorall_type</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if DocumentFragment.querySelectorAll() method is of type function" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function() {
+ var frag = document.createDocumentFragment();
+ assert_equals(typeof frag.querySelectorAll, "function", "The type of documentfragment.querySelectorAll");
+ }, document.title);
+ </script>
+ </body>
+</html>
var element = document.getElementById("log");
assert_true("querySelector" in element,document.title);
});
- </script>
+ </script>
</body>
</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_element_queryselector_no_argument</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if element.querySelector() method without arguments that must excepting TypeError exception is to be thrown" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <form id="element"></form>
+ <script>
+ test(function () {
+ var element = document.getElementById("element");
+ try {
+ var sel = element.querySelector();
+ assert_true(false, "it should throw exception");
+ }
+ catch (e) {
+ assert_true(e.message == "Not enough arguments", "TypeError exception is to be thrown");
+ }
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_element_queryselector_return_first</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if element.querySelector() method must return the first matching Element node within the subtrees of the context node" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <form id="element" style="display:none;">
+ <input id="txt1" type="text" />
+ <input id="txt2" type="text" />
+ </form>
+ <script>
+ test(function () {
+ var element = document.getElementById("element");
+ assert_equals(element.querySelector("#txt1,#txt2").id, "txt1", "the return value");
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_element_queryselector_type</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if element.querySelector() method is of type function" />
+ <script type="text/javascript" src="../resources/testharness.js"></script>
+ <script type="text/javascript" src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script type="text/javascript">
+ test(function() {
+ var element = document.getElementById("log");
+ assert_equals(typeof element.querySelector, "function", document.title);
+ });
+ </script>
+ </body>
+</html>
var element = document.getElementById("log");
assert_true("querySelectorAll" in element,document.title);
});
- </script>
+ </script>
</body>
</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_element_queryselectorall_no_argument</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if element.querySelectorAll() method without arguments that must excepting TypeError exception is to be thrown" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function () {
+ try {
+ var sel = document.querySelectorAll();
+ assert_true(false, "it should throw exception");
+ }
+ catch (e) {
+ assert_true(e.message == "Not enough arguments", "TypeError exception is to be thrown");
+ }
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_element_queryselectorall_return_nodelist</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if element.querySelectorAll() method must return a NodeList containing all of the matching Element nodes within the subtrees of the context node, in document order" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <form id="element">
+ <input id="txt1" type="text" />
+ </form>
+ <script>
+ test(function () {
+ var element = document.getElementById("element");
+ assert_equals(element.querySelectorAll("#txt1").toString(), "[object NodeList]", "the return type");
+ }, document.title);
+ </script>
+ </body>
+</html>
--- /dev/null
+<!DOCTYPE html>
+<!--
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+ of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+ may be used to endorse or promote products derived from this work without
+ specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+ Xu, Yi <yix.xu@intel.com>
+ Cui, Jieqiong <jieqiongx.cui@intel.com>
+
+-->
+
+<html>
+ <head>
+ <title>Selectors API Level1 Test: selectors1_element_queryselectorall_type</title>
+ <link rel="author" title="Intel" href="http://www.intel.com/" />
+ <link rel="help" href="http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions" />
+ <meta name="flags" content="" />
+ <meta name="assert" content="Check if element.querySelectorAll() method is of type function" />
+ <script src="../resources/testharness.js"></script>
+ <script src="../resources/testharnessreport.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ test(function() {
+ var element = document.getElementById("log");
+ assert_equals(typeof element.querySelectorAll, "function", "the type of element.queryselectorall");
+ }, document.title);
+ </script>
+ </body>
+</html>
</spec>
</specs>
</testcase>
+ <testcase purpose="Check if DocumentFragment.querySelectorAll() method without arguments that must excepting TypeError exception is to be thrown" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P3" id="selectors1_documentfragment_queryselectorall_no_argument">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if DocumentFragment.querySelectorAll() method without arguments that must excepting TypeError exception is to be thrown</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_documentfragment_queryselectorall_no_argument.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion usage="true" interface="DocumentFragment" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if DocumentFragment.querySelectorAll() method return a NodeList containing all of the matching Element nodes within the subtrees of the context node, in document order" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_documentfragment_queryselectorall_return_nodelist">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if DocumentFragment.querySelectorAll() method return a NodeList containing all of the matching Element nodes within the subtrees of the context node, in document order</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_documentfragment_queryselectorall_return_nodelist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelectorAll" interface="DocumentFragment" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if DocumentFragment.querySelectorAll() method is of type function" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_documentfragment_queryselectorall_type">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if DocumentFragment.querySelectorAll() method is of type function</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_documentfragment_queryselectorall_type.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelectorAll" interface="DocumentFragment" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if DocumentFragment.querySelector() method must return the first matching Element node within the subtrees of the context node" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_documentfragment_queryselector_return_first">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if DocumentFragment.querySelector() method must return the first matching Element node within the subtrees of the context node</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_documentfragment_queryselector_return_first.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelector" interface="DocumentFragment" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if DocumentFragment.querySelector() method is of type function" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_documentfragment_queryselector_type">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if DocumentFragment.querySelector() method is of type function</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_documentfragment_queryselector_type.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelector" interface="DocumentFragment" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if DocumentFragment.querySelector() method without arguments that must excepting TypeError exception is to be thrown" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P3" id="selectors1_documentfragment_queryselector_no_argument">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if DocumentFragment.querySelector() method without arguments that must excepting TypeError exception is to be thrown</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_documentfragment_queryselector_no_argument.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion usage="true" interface="DocumentFragment" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if document.querySelectorAll() method without arguments that must excepting TypeError exception is to be thrown" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P3" id="selectors1_document_queryselectorall_no_argument">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if document.querySelectorAll() method without arguments that must excepting TypeError exception is to be thrown</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_document_queryselectorall_no_argument.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion usage="true" interface="Document" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if document.querySelectorAll() method return a NodeList containing all of the matching Element nodes within the subtrees of the context node" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_document_queryselectorall_return_nodelist">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if document.querySelectorAll() method return a NodeList containing all of the matching Element nodes within the subtrees of the context node</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_document_queryselectorall_return_nodelist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelectorAll" interface="Document" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if document.querySelectorAll() method is of type function" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_document_queryselectorall_type">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if document.querySelectorAll() method is of type function</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_document_queryselectorall_type.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelectorAll" interface="Document" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if document.querySelector() method without arguments that must excepting TypeError exception is to be thrown" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P3" id="selectors1_document_queryselector_no_argument">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if document.querySelector() method without arguments that must excepting TypeError exception is to be thrown</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_document_queryselector_no_argument.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion usage="true" interface="Document" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if document.querySelector() method return null if there is no matching Element" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_document_queryselector_return_null">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if document.querySelector() method return null if there is no matching Element</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_document_queryselector_return_null.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelector" interface="Document" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if document.querySelector() method is of type function" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_document_queryselector_type">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if document.querySelector() method is of type function</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_document_queryselector_type.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelector" interface="Document" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if element.querySelectorAll() method without arguments that must excepting TypeError exception is to be thrown" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P3" id="selectors1_element_queryselectorall_no_argument">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if element.querySelectorAll() method without arguments that must excepting TypeError exception is to be thrown</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_element_queryselectorall_no_argument.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion usage="true" interface="Element" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if element.querySelectorAll() method must return a NodeList containing all of the matching Element nodes within the subtrees of the context node, in document order" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_element_queryselectorall_return_nodelist">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if element.querySelectorAll() method must return a NodeList containing all of the matching Element nodes within the subtrees of the context node, in document order</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_element_queryselectorall_return_nodelist.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelectorAll" interface="Element" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if element.querySelectorAll() method is of type function" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_element_queryselectorall_type">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if element.querySelectorAll() method is of type function</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_element_queryselectorall_type.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelectorAll" interface="Element" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if element.querySelector() method without arguments that must excepting TypeError exception is to be thrown" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P3" id="selectors1_element_queryselector_no_argument">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if element.querySelector() method without arguments that must excepting TypeError exception is to be thrown</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_element_queryselector_no_argument.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion usage="true" interface="Element" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if element.querySelector() method must return the first matching Element node within the subtrees of the context node" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_element_queryselector_return_first">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if element.querySelector() method must return the first matching Element node within the subtrees of the context node</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_element_queryselector_return_first.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelector" interface="Element" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
+ <testcase purpose="Check if element.querySelector() method is of type function" type="compliance" status="approved" component="WebAPI/DOM, Forms and Styles/Selectors API Level 1" execution_type="auto" priority="P2" id="selectors1_element_queryselector_type">
+ <description>
+ <pre_condition/>
+ <post_condition/>
+ <steps>
+ <step order="1">
+ <step_desc>Check if element.querySelector() method is of type function</step_desc>
+ <expected>Pass</expected>
+ </step>
+ </steps>
+ <test_script_entry>/opt/tct-selectorslevel1-w3c-tests/selectorslevel1/selectors1_element_queryselector_type.html</test_script_entry>
+ </description>
+ <specs>
+ <spec>
+ <spec_assertion element_type="method" element_name="querySelector" interface="Element" specification="Selectors API Level 1" section="DOM, Forms and Styles" category="Tizen W3C API Specifications"/>
+ <spec_url>http://www.w3.org/TR/2012/WD-selectors-api-20120628/#interface-definitions</spec_url>
+ <spec_statement/>
+ </spec>
+ </specs>
+ </testcase>
</set>
</suite>
</test_definition>