OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 19275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
19286 CHECK(try_catch.HasCaught()); | 19286 CHECK(try_catch.HasCaught()); |
19287 } | 19287 } |
19288 | 19288 |
19289 CheckCorrectThrow("other.x"); | 19289 CheckCorrectThrow("other.x"); |
19290 CheckCorrectThrow("other[1]"); | 19290 CheckCorrectThrow("other[1]"); |
19291 CheckCorrectThrow("JSON.stringify(other)"); | 19291 CheckCorrectThrow("JSON.stringify(other)"); |
19292 CheckCorrectThrow("has_own_property(other, 'x')"); | 19292 CheckCorrectThrow("has_own_property(other, 'x')"); |
19293 CheckCorrectThrow("%GetProperty(other, 'x')"); | 19293 CheckCorrectThrow("%GetProperty(other, 'x')"); |
19294 CheckCorrectThrow("%SetProperty(other, 'x', 'foo', 0)"); | 19294 CheckCorrectThrow("%SetProperty(other, 'x', 'foo', 0)"); |
19295 CheckCorrectThrow("%AddNamedProperty(other, 'x', 'foo', 1)"); | 19295 CheckCorrectThrow("%AddNamedProperty(other, 'x', 'foo', 1)"); |
19296 CheckCorrectThrow("%DeleteProperty(other, 'x', 0)"); | 19296 CheckCorrectThrow("%DeleteProperty_Sloppy(other, 'x')"); |
19297 CheckCorrectThrow("%DeleteProperty(other, '1', 0)"); | 19297 CheckCorrectThrow("%DeleteProperty_Strict(other, 'x')"); |
| 19298 CheckCorrectThrow("%DeleteProperty_Sloppy(other, '1')"); |
| 19299 CheckCorrectThrow("%DeleteProperty_Strict(other, '1')"); |
19298 CheckCorrectThrow("%HasOwnProperty(other, 'x')"); | 19300 CheckCorrectThrow("%HasOwnProperty(other, 'x')"); |
19299 CheckCorrectThrow("%HasProperty(other, 'x')"); | 19301 CheckCorrectThrow("%HasProperty(other, 'x')"); |
19300 CheckCorrectThrow("%HasElement(other, 1)"); | 19302 CheckCorrectThrow("%HasElement(other, 1)"); |
19301 CheckCorrectThrow("%IsPropertyEnumerable(other, 'x')"); | 19303 CheckCorrectThrow("%IsPropertyEnumerable(other, 'x')"); |
19302 // PROPERTY_ATTRIBUTES_NONE = 0 | 19304 // PROPERTY_ATTRIBUTES_NONE = 0 |
19303 CheckCorrectThrow("%DefineAccessorPropertyUnchecked(" | 19305 CheckCorrectThrow("%DefineAccessorPropertyUnchecked(" |
19304 "other, 'x', null, null, 1)"); | 19306 "other, 'x', null, null, 1)"); |
19305 | 19307 |
19306 // Reset the failed access check callback so it does not influence | 19308 // Reset the failed access check callback so it does not influence |
19307 // the other tests. | 19309 // the other tests. |
(...skipping 2510 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
21818 CHECK(try_catch.HasTerminated()); | 21820 CHECK(try_catch.HasTerminated()); |
21819 } | 21821 } |
21820 | 21822 |
21821 | 21823 |
21822 TEST(EstimatedContextSize) { | 21824 TEST(EstimatedContextSize) { |
21823 v8::Isolate* isolate = CcTest::isolate(); | 21825 v8::Isolate* isolate = CcTest::isolate(); |
21824 v8::HandleScope scope(isolate); | 21826 v8::HandleScope scope(isolate); |
21825 LocalContext env; | 21827 LocalContext env; |
21826 CHECK(50000 < env->EstimatedSize()); | 21828 CHECK(50000 < env->EstimatedSize()); |
21827 } | 21829 } |
OLD | NEW |