(#12412) Refactor puppet_resource('exec')
Previously, the exec tests did not run on Windows, because they tried
using Unix utilities within an exec resource, e.g. /bin/touch.
This commit uses the exec methods on the agent instances instead to
generate an appropriate command for that platform. In the process, it
also uncovered an issue whereby multi-line commands don't work on
Windows (#9996). This is because Windows doesn't support a shell exec
provider, and so this test is skipped on Windows agents.
The should_run_command test also demonstrates a known race condition
in Windows (#11740) which can cause the child process to exit before
the parent has a chance to get its exit code. This test will warn on
Windows agents, and once #11740 is fixed, we can re-enable the
acceptance test.