You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- <?php
- class ErrorTest_53 extends SimpleTest {
- function test_1_error_handler() {
- global $anonymous_error_callback_worked;
-
- DB::$throw_exception_on_error = false;
- DB::$error_handler = function($params) {
- global $anonymous_error_callback_worked;
- if (substr_count($params['error'], 'You have an error in your SQL syntax')) $anonymous_error_callback_worked = 1;
- };
- DB::query("SELET * FROM accounts");
- $this->assert($anonymous_error_callback_worked === 1);
-
- }
-
-
- }
-
- ?>
|