Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Side by Side Diff: LayoutTests/inspector/console/console-eval-throw.html

Issue 369333002: DevTools: Added error message when the command is invoked from the console with exception (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@add-evaluate-exception-details
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <html>
2 <head>
3 <script src="../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../http/tests/inspector/console-test.js"></script>
5 <script>
6 function test()
7 {
8 function dumpMessages(next, message)
9 {
10 InspectorTest.dumpConsoleMessages();
11 next();
12 }
13
14 InspectorTest.runTestSuite([
15 function testThrowUndefined(next)
16 {
17 InspectorTest.evaluateInConsole('throw undefined', dumpMessages.bind (null, next));
18 },
19
20 function testThrowNumber(next)
21 {
22 InspectorTest.evaluateInConsole('throw 1', dumpMessages.bind(null, n ext));
23 },
24
25 function testThrowString(next)
26 {
27 InspectorTest.evaluateInConsole('throw \'asdf\'', dumpMessages.bind( null, next));
28 },
29
30 function testThrowObject(next)
31 {
32 InspectorTest.evaluateInConsole('throw {a:42}', dumpMessages.bind(nu ll, next));
33 },
34
35 function testThrowError(next)
36 {
37 InspectorTest.evaluateInConsole('throw new Error(\'asdf\')', dumpMes sages.bind(null, next));
38 }
39 ]);
40 }
41 </script>
42 </head>
43 <body onload="runTest()">
44 <p>
45 Tests that evaluating 'throw undefined|1|string|object|Error' in the console won 't crash the browser and correctly reported.
46 <a href="https://bugs.webkit.org/show_bug.cgi?id=59611">Bug 59611.</a>
47 </p>
48 </body>
49 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698