Same as you would with your own code. You review it, ask GPT to write tests, and then tweak it.
The difference is that now, you are more of a code reviewer and editor. You don't have to sit there and figure out the library interface and type out every single line.