Split some test helpers into a utils namespace.