Refactor out util.make_tests