refactor print_model_ids for easier testing
add failing test for bug when piped to xargs -0

It looks like `xargs -0` expects single arguments to also be null
terminated.
even a single ID needs to be null terminated
fix issue that broke piping to xargs -0