Fix failing tests on old perl