fixed logic err in test example