Test: cts-cli,cts-pengine: avoid sed -i
"sed -i" isn't POSIX, and its usage differs in GNU sed and BSD sed,
so avoid it in regression tests.
It should be handled similarly in other places where it remains, but this will
help get the BSD build working.