From: "Brian C. Lane" bcl@redhat.com
This way you can do export PYTHONPATH=/path/to/py3lorax before running the tests on a f22 system where lorax is still python2. --- tests/kickstart_tests/run_kickstart_tests.sh | 4 ++-- tests/kickstart_tests/run_one_ks.sh | 1 + 2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/tests/kickstart_tests/run_kickstart_tests.sh b/tests/kickstart_tests/run_kickstart_tests.sh index 169ef68..630813c 100755 --- a/tests/kickstart_tests/run_kickstart_tests.sh +++ b/tests/kickstart_tests/run_kickstart_tests.sh @@ -132,7 +132,7 @@ if [[ "$TEST_REMOTES" != "" ]]; then
parallel --no-notice ${remote_args} \ ${env_args} --jobs ${TEST_JOBS:-2} \ - sudo kickstart_tests/run_one_ks.sh -i ${_IMAGE} -k ${KEEPIT} {} ::: ${tests} + sudo PYTHONPATH=$PYTHONPATH kickstart_tests/run_one_ks.sh -i ${_IMAGE} -k ${KEEPIT} {} ::: ${tests} rc=$?
# (3) Get all the results back from the remote systems, which will have already @@ -159,7 +159,7 @@ if [[ "$TEST_REMOTES" != "" ]]; then exit ${rc} else parallel --no-notice ${env_args} --jobs ${TEST_JOBS:-2} \ - sudo kickstart_tests/run_one_ks.sh -i ${IMAGE} -k ${KEEPIT} {} ::: ${tests} + sudo PYTHONPATH=$PYTHONPATH kickstart_tests/run_one_ks.sh -i ${IMAGE} -k ${KEEPIT} {} ::: ${tests}
# For future expansion - any cleanup code can go in between the variable # setting and the exit, like in the other branch of the if-else above. diff --git a/tests/kickstart_tests/run_one_ks.sh b/tests/kickstart_tests/run_one_ks.sh index b84607f..b5234d9 100755 --- a/tests/kickstart_tests/run_one_ks.sh +++ b/tests/kickstart_tests/run_one_ks.sh @@ -86,6 +86,7 @@ runone() { disks=$(prepare_disks ${tmpdir}) disk_args=$(for d in $disks; do echo --disk $d; done)
+ echo "PYTHONPATH=$PYTHONPATH" eval ${KSTESTDIR}/kstest-runner ${kargs} \ --iso "${tmpdir}/$(basename ${IMAGE})" \ --ks ${ksfile} \