Browse Source

Use generic user for both zuul v2 and v3

Zuul v2 uses 'jenkins' as user, but Zuul v3 uses 'zuul'.
Using $USER solves it for both cases.

Change-Id: Ida42122c0ad2fa123c2e245acfa4be5f964180a2
changes/99/512499/2
Nam Nguyen Hoai 2 years ago
parent
commit
8672cf0c92
1 changed files with 3 additions and 3 deletions
  1. +3
    -3
      ceilometerclient/tests/functional/hooks/post_test_hook.sh

+ 3
- 3
ceilometerclient/tests/functional/hooks/post_test_hook.sh View File

@@ -21,7 +21,7 @@ function generate_testr_results {
sudo /usr/os-testr-env/bin/subunit2html $BASE/logs/testrepository.subunit $BASE/logs/testr_results.html
sudo gzip -9 $BASE/logs/testrepository.subunit
sudo gzip -9 $BASE/logs/testr_results.html
sudo chown jenkins:jenkins $BASE/logs/testrepository.subunit.gz $BASE/logs/testr_results.html.gz
sudo chown $USER:$USER $BASE/logs/testrepository.subunit.gz $BASE/logs/testr_results.html.gz
sudo chmod a+r $BASE/logs/testrepository.subunit.gz $BASE/logs/testr_results.html.gz
fi
}
@@ -35,13 +35,13 @@ source openrc admin admin
# Go to the ceilometerclient dir
cd $CEILOMETERCLIENT_DIR

sudo chown -R jenkins:stack $CEILOMETERCLIENT_DIR
sudo chown -R $USER:stack $CEILOMETERCLIENT_DIR

# Run tests
echo "Running ceilometerclient functional test suite"
set +e
# Preserve env for OS_ credentials
sudo -E -H -u jenkins tox -efunctional
sudo -E -H -u $USER tox -efunctional
EXIT_CODE=$?
set -e



Loading…
Cancel
Save