I was, too, and I agree, but Trump is nothing if not practical. He needs everyone possible on board to accomplish great things, especially quickly, and Cruz is influential and bright. The smarmy, self-absorbed crap can be kept in a box, and Trump can have it taken to the trash if needed.
I'm inspired by Cruz's stands againt the rest of Congress but honestly, who does Cruz influence? He was and still is "a voice crying in the wilderness."