OLD | NEW |
1 // Copyright 2007-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2007-2008 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 2728 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2739 CHECK(CompileRun(source)->BooleanValue()); | 2739 CHECK(CompileRun(source)->BooleanValue()); |
2740 | 2740 |
2741 source = "both_values[2].name() == 'c'"; | 2741 source = "both_values[2].name() == 'c'"; |
2742 CHECK(CompileRun(source)->BooleanValue()); | 2742 CHECK(CompileRun(source)->BooleanValue()); |
2743 | 2743 |
2744 source = "both_values[3].name() == 1"; | 2744 source = "both_values[3].name() == 1"; |
2745 CHECK(CompileRun(source)->BooleanValue()); | 2745 CHECK(CompileRun(source)->BooleanValue()); |
2746 | 2746 |
2747 source = "both_values[4].name() == 10"; | 2747 source = "both_values[4].name() == 10"; |
2748 CHECK(CompileRun(source)->BooleanValue()); | 2748 CHECK(CompileRun(source)->BooleanValue()); |
2749 | |
2750 // Check the property values. | |
2751 source = "both_values[0].value().value() == 'AA'"; | |
2752 CHECK(CompileRun(source)->BooleanValue()); | |
2753 | |
2754 source = "both_values[1].value().value() == 'BB'"; | |
2755 CHECK(CompileRun(source)->BooleanValue()); | |
2756 | |
2757 source = "both_values[2].value().value() == 'CC'"; | |
2758 CHECK(CompileRun(source)->BooleanValue()); | |
2759 | |
2760 source = "both_values[3].value().value() == 2"; | |
2761 CHECK(CompileRun(source)->BooleanValue()); | |
2762 | |
2763 source = "both_values[4].value().value() == 11"; | |
2764 CHECK(CompileRun(source)->BooleanValue()); | |
2765 } | 2749 } |
2766 | 2750 |
2767 | 2751 |
2768 // Multithreaded tests of JSON debugger protocol | 2752 // Multithreaded tests of JSON debugger protocol |
2769 | 2753 |
2770 // Support classes | 2754 // Support classes |
2771 | 2755 |
2772 // Copies a C string to a 16-bit string. Does not check for buffer overflow. | 2756 // Copies a C string to a 16-bit string. Does not check for buffer overflow. |
2773 // Does not use the V8 engine to convert strings, so it can be used | 2757 // Does not use the V8 engine to convert strings, so it can be used |
2774 // in any thread. Returns the length of the string. | 2758 // in any thread. Returns the length of the string. |
(...skipping 645 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3420 " CheckSourceLine(2)\n" | 3404 " CheckSourceLine(2)\n" |
3421 " CheckSourceLine(3)\n" | 3405 " CheckSourceLine(3)\n" |
3422 "}; f()"))->Run(); | 3406 "}; f()"))->Run(); |
3423 | 3407 |
3424 // Test that a parameter can be passed to a function called in the debugger. | 3408 // Test that a parameter can be passed to a function called in the debugger. |
3425 v8::Script::Compile(v8::String::New("CheckDataParameter()"))->Run(); | 3409 v8::Script::Compile(v8::String::New("CheckDataParameter()"))->Run(); |
3426 | 3410 |
3427 // Test that a function with closure can be run in the debugger. | 3411 // Test that a function with closure can be run in the debugger. |
3428 v8::Script::Compile(v8::String::New("CheckClosure()"))->Run(); | 3412 v8::Script::Compile(v8::String::New("CheckClosure()"))->Run(); |
3429 } | 3413 } |
OLD | NEW |