better way of fixing tests