Lines Matching refs:scope
79 // Check that the scope chain contains the expected types of scopes.
83 var scope = exec_state.frame().scope(i);
84 assertTrue(scope.isScope());
85 assertEquals(scopes[i], scope.scopeType());
87 // Check the global object when hitting the global scope.
91 assertPropertiesEqual(this, scope.scopeObject().value());
117 assertTrue(found, "Scope object " + response.body.scopes[i].object.ref + " not found");
122 // Check that the content of the scope is as expected. For functions just check
125 var scope = exec_state.frame().scope(number);
128 var property_mirror = scope.scopeObject().property(p);
129 assertFalse(property_mirror.isUndefined(), 'property ' + p + ' not found in scope');
138 // 'arguments' and might be exposed in the local and closure scope. Just
140 var scope_size = scope.scopeObject().properties().length;
141 if (!scope.scopeObject().property('arguments').isUndefined()) {
145 if (!scope.scopeObject().property('.catch-var').isUndefined()) {
149 if (!scope.scopeObject().property('').isUndefined()) {
154 print('Names found in scope:');
155 var names = scope.scopeObject().propertyNames();
165 // Send a scope request for information on a single scope and check the
167 var request_json = '{"seq":0,"type":"request","command":"scope","arguments":{"number":';
168 request_json += scope.scopeIndex();
172 assertEquals(scope.scopeType(), response.body.type);
174 if (scope.scopeType() == debug.ScopeType.Local ||
175 scope.scopeType() == debug.ScopeType.Closure) {
184 assertTrue(found, "Scope object " + response.body.object.ref + " not found");
188 // Simple empty local scope.
204 // Local scope with a parameter.
220 // Local scope with a parameter and a local variable.
237 // Local scope with parameters and local variables.
255 // Empty local scope with use of eval.
289 // Local scope with parameters, local variables and local variable introduced
413 assertEquals(exec_state.frame().scope(0).scopeObject(), exec_state.frame().scope(1).scopeObject());
414 assertEquals(with_object, exec_state.frame().scope(1).scopeObject().value());
428 assertEquals(exec_state.frame().scope(0).scopeObject(), exec_state.frame().scope(1).scopeObject());
429 assertEquals(with_object, exec_state.frame().scope(1).scopeObject().value());
831 // Test global scope.
935 // Test catch in global scope.