Adjust tests to be compatible with PHPUnit 10 (#998) This avoids warnings on PHPUnit 10, without actually switching to PHPUnit 10.