From 7a80be1f588a9b6f9b3b04a089c0de855ea41053 Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Wed, 26 Apr 2017 14:38:30 +0200 Subject: [PATCH] Rename GNOCCHI_SERVICE_URL to GNOCCHI_ENDPOINT That makes it possible to use directly pifpaf variables. Change-Id: I89dc322330ceb030965df25cc062b7255efa5775 --- devstack/gate/post_test_hook.sh | 4 ++-- gnocchi/tests/functional_live/test_gabbi_live.py | 4 ++-- run-func-tests.sh | 1 - 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/devstack/gate/post_test_hook.sh b/devstack/gate/post_test_hook.sh index 91e56c56..f4a89086 100755 --- a/devstack/gate/post_test_hook.sh +++ b/devstack/gate/post_test_hook.sh @@ -39,10 +39,10 @@ cd $GNOCCHI_DIR openstack catalog list export GNOCCHI_SERVICE_TOKEN=$(openstack token issue -c id -f value) -export GNOCCHI_SERVICE_URL=$(openstack catalog show metric -c endpoints -f value | awk '/public/{print $2}') +export GNOCCHI_ENDPOINT=$(openstack catalog show metric -c endpoints -f value | awk '/public/{print $2}') export GNOCCHI_AUTHORIZATION="" # Temporary set to transition to the new functional testing -curl -X GET ${GNOCCHI_SERVICE_URL}/v1/archive_policy -H "Content-Type: application/json" +curl -X GET ${GNOCCHI_ENDPOINT}/v1/archive_policy -H "Content-Type: application/json" sudo gnocchi-upgrade diff --git a/gnocchi/tests/functional_live/test_gabbi_live.py b/gnocchi/tests/functional_live/test_gabbi_live.py index 9e013a9e..aeed07a8 100644 --- a/gnocchi/tests/functional_live/test_gabbi_live.py +++ b/gnocchi/tests/functional_live/test_gabbi_live.py @@ -26,7 +26,7 @@ TESTS_DIR = 'gabbits' def load_tests(loader, tests, pattern): """Provide a TestSuite to the discovery process.""" - gnocchi_url = os.getenv('GNOCCHI_SERVICE_URL') + gnocchi_url = os.getenv('GNOCCHI_ENDPOINT') if gnocchi_url: parsed_url = urlparse.urlsplit(gnocchi_url) prefix = parsed_url.path.rstrip('/') # turn it into a prefix @@ -45,4 +45,4 @@ def load_tests(loader, tests, pattern): port=port, prefix=prefix) elif os.getenv("GABBI_LIVE"): - raise RuntimeError('"GNOCCHI_SERVICE_URL" is not set') + raise RuntimeError('"GNOCCHI_ENDPOINT" is not set') diff --git a/run-func-tests.sh b/run-func-tests.sh index 4d702208..2e8ecd74 100755 --- a/run-func-tests.sh +++ b/run-func-tests.sh @@ -44,7 +44,6 @@ for storage in ${GNOCCHI_TEST_STORAGE_DRIVERS}; do eval $(pifpaf -e INDEXER run $indexer) eval $(pifpaf -e GNOCCHI run gnocchi --indexer-url $INDEXER_URL --storage-url $STORAGE_URL) - export GNOCCHI_SERVICE_URL=$GNOCCHI_ENDPOINT export GNOCCHI_SERVICE_TOKEN="" # Just make gabbi happy export GNOCCHI_AUTHORIZATION="basic YWRtaW46" # admin in base64 export OS_TEST_PATH=gnocchi/tests/functional_live