Fix test framework errors on PHP 5.4.