diff options
author | Vincent Sanders <vince@kyllikki.org> | 2012-11-01 21:12:21 +0000 |
---|---|---|
committer | Vincent Sanders <vince@kyllikki.org> | 2012-11-01 21:12:21 +0000 |
commit | 8f08f820f4d17173c08d121a1bd50e1afe66724c (patch) | |
tree | b13588019130adc1e84e0e53e60b74d3e05e9fee | |
parent | 5496a604310b65db0513c063ed171f0168baee28 (diff) | |
download | netsurf-8f08f820f4d17173c08d121a1bd50e1afe66724c.tar.gz netsurf-8f08f820f4d17173c08d121a1bd50e1afe66724c.tar.bz2 |
improve tests
-rw-r--r-- | test/js/doc-dom2.html | 12 | ||||
-rw-r--r-- | test/js/index.html | 2 |
2 files changed, 9 insertions, 5 deletions
diff --git a/test/js/doc-dom2.html b/test/js/doc-dom2.html index 17a916c81..a55962bed 100644 --- a/test/js/doc-dom2.html +++ b/test/js/doc-dom2.html @@ -4,9 +4,13 @@ <link rel="stylesheet" type="text/css" href="tst.css"> </head> <body> -<h1 id="heading">Direct DOM element reference</h1> -<p>Before</p> -<script>document.write(document.getElementById("heading").textContent);</script> -<p>Afterwards</p> +<h1>DOM getElementById element reference</h1> +<p>This shows the text content of an element obtained using <a href="http://dom.spec.whatwg.org/#dom-document-getelementbyid">document.getElementById</a></p> +<p>Referenced text</p> +<p id="reftext">DOM getElementById element referenced test text</p> +<p>Inserted text</p> +<p><script>document.write(document.getElementById("reftext").textContent);</script></p> +<p>After inserted text</p> + </body> </html> diff --git a/test/js/index.html b/test/js/index.html index a7d34f5a1..f618e93c5 100644 --- a/test/js/index.html +++ b/test/js/index.html @@ -10,7 +10,7 @@ </ul> <h2>Document write tests</h2> <ul> -<li><a href="inline-doc-write-simple.html">Simple docuemnt write</a></li> +<li><a href="inline-doc-write-simple.html">Simple document write</a></li> <li><a href="noscript-inline-doc-write.html">Script within inline script document write with noscript alternative</a></li> <li><a href="inline-doc-write.html">Script within inline script</a></li> <li><a href="sync-script.html">External syncronous script</a></li> |