fixed tests to run on php-5.2