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

Unified Diff: test/mjsunit/debug-compile-event.js

Issue 352583008: Rollback to Version 3.28.4 (based on bleeding_edge revision r22031) (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: Created 6 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/cctest/test-parsing.cc ('k') | test/mjsunit/mjsunit.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/debug-compile-event.js
diff --git a/test/mjsunit/debug-compile-event.js b/test/mjsunit/debug-compile-event.js
index 477c01d7f867d71c8afc2544ef01e5d6fdd0ee83..89a71ddb598197f4586c9cf99b3ac76f2a9b5019 100644
--- a/test/mjsunit/debug-compile-event.js
+++ b/test/mjsunit/debug-compile-event.js
@@ -32,7 +32,6 @@ Debug = debug.Debug
var exception = false; // Exception in debug event listener.
var before_compile_count = 0;
var after_compile_count = 0;
-var compile_error_count = 0;
var current_source = ''; // Current source being compiled.
var source_count = 0; // Total number of scources compiled.
var host_compilations = 0; // Number of scources compiled through the API.
@@ -49,12 +48,11 @@ function compileSource(source) {
function listener(event, exec_state, event_data, data) {
try {
if (event == Debug.DebugEvent.BeforeCompile ||
- event == Debug.DebugEvent.AfterCompile ||
- event == Debug.DebugEvent.CompileError) {
+ event == Debug.DebugEvent.AfterCompile) {
// Count the events.
if (event == Debug.DebugEvent.BeforeCompile) {
before_compile_count++;
- } else if (event == Debug.DebugEvent.AfterCompile) {
+ } else {
after_compile_count++;
switch (event_data.script().compilationType()) {
case Debug.ScriptCompilationType.Host:
@@ -64,8 +62,6 @@ function listener(event, exec_state, event_data, data) {
eval_compilations++;
break;
}
- } else {
- compile_error_count++;
}
// If the compiled source contains 'eval' there will be additional compile
@@ -109,17 +105,11 @@ compileSource('JSON.parse(\'{"a":1,"b":2}\')');
// Using JSON.parse does not causes additional compilation events.
compileSource('x=1; //# sourceURL=myscript.js');
-try {
- compileSource('}');
-} catch(e) {
-}
-
// Make sure that the debug event listener was invoked.
assertFalse(exception, "exception in listener")
-// Number of before and after + error events should be the same.
-assertEquals(before_compile_count, after_compile_count + compile_error_count);
-assertEquals(compile_error_count, 1);
+// Number of before and after compile events should be the same.
+assertEquals(before_compile_count, after_compile_count);
// Check the actual number of events (no compilation through the API as all
// source compiled through eval).
« no previous file with comments | « test/cctest/test-parsing.cc ('k') | test/mjsunit/mjsunit.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698