OLD | NEW |
---|---|
(Empty) | |
1 <html> | |
2 <head> | |
3 </head> | |
4 <body> | |
5 <div id='test'> | |
6 <p id='start'>start</p> | |
7 <p id='end'>end</p> | |
8 </div> | |
9 <script> | |
10 if (window.testRunner) | |
11 testRunner.dumpAsText(); | |
12 | |
13 var range = document.createRange(); | |
14 range.setStart(document, 0); | |
15 range.setEnd(document, 1); | |
16 try { | |
17 range.deleteContents(); | |
18 console.log('Ran as expected!'); | |
yosin_UTC9
2014/08/11 00:34:24
We can use |shouldThrow| in "js-test.js".
kangil_
2014/08/11 00:42:20
Yes, I usually use it. But, in this case,
shouldNo
yosin_UTC9
2014/08/11 02:16:42
I see. How about using document.write, document.do
kangil_
2014/08/11 04:00:20
Done.
| |
19 } catch (e) { | |
20 console.log('should not be here..' + e); | |
21 } | |
22 </script> | |
23 </body> | |
24 </html> | |
OLD | NEW |