Commit
452a888e4d109dee6559f5130c8000aa09c0fd60
by Oliver Smith
testenv: testsuite: use rsync with --archive
When running in podman, the source files from the testsuite get copied to a temporary directory to build the testsuites out-of-tree (avoiding conflicts with possibly incompatible binary objects that may exist from previously building the testsuites on the host).
This also copies additional scripts for preparation / clean up that may be used in testenv.cfg. Use the --archive flag with rsync to ensure that the executability is the same. I could have also used --executability, but --archive contains two other existing flags and more flags which may help us from running into unexpected situations such as this one.
Without this patch, there was a bug when: * first creating a shell script but not making it executable * running testenv with podman (where rsync runs and creates the file initially without executable permissions) * making the script executable * running testenv with podman again, rsync will not adjust the permissions for the copy of the file * user wonders why there is a "sh: 1: script.sh: Permission denied" error
Commit
50ae2377c5b423b0836a76791780b19495e69477
by Oliver Smith
testenv: podman.exec_cmd: better error if stopped
Testenv may try to run a comand in podman after the container was stopped, if there is a bug in the shutdown logic. Give a meaningful error in that case, instead of failing later on with a cryptic error in subprocess.run() because None was passed inside cmd (for the container name) instead of a string.
Commit
a247aa34831cf0a5580a8e24a0702956392bf032
by Oliver Smith
testenv: copy=: support copying directories too
In preparation for adding the inital testenv.cfgs for ggsn, allow copying full directories with copy= too. This will make the ggsn testenv.cfg files easier to maintain.