More robust phpunit tests