Set Tempest's service_availability setting for Aodh

Tempest's service_available config option includes all the service
availability which is further used by tests to take decision of skip
or run the test.

For example, [service_available].aodh is true then, aodh test will run
or if [service_available].aodh is false then, all aodh related tests either
in telemetry tempest plugin or any other plugins will be skipped.

This commit add the setting of aodh service[1] on aodh devstack plugin.

Closes-Bug: #1743688
[1] https://github.com/openstack/telemetry-tempest-plugin/blob/master/telemetry_tempest_plugin/config.py#L27

Change-Id: Idac9f38aac6964ce4d40b6afccbd9dfbf6e16a41
This commit is contained in:
ghanshyam 2018-11-26 10:19:39 +00:00 committed by Lingxian Kong
parent 6aa6fd0626
commit 0e40e57c1a
1 changed files with 12 additions and 0 deletions

View File

@ -291,6 +291,15 @@ function start_aodh {
run_process aodh-listener "$AODH_BIN_DIR/aodh-listener --config-file $AODH_CONF"
}
# configure_tempest_for_aodh()
# NOTE (gmann): Configure all the Tempest setting for Aodh service in
# this function.
function configure_tempest_for_aodh {
if is_service_enabled tempest; then
iniset $TEMPEST_CONFIG service_available aodh True
fi
}
# stop_aodh() - Stop running processes
function stop_aodh {
if [ "$AODH_DEPLOY" == "mod_wsgi" ]; then
@ -322,6 +331,9 @@ if is_service_enabled aodh; then
init_aodh
# Start the services
start_aodh
elif [[ "$1" == "stack" && "$2" == "test-config" ]]; then
echo_summary "Configuring Tempest for Aodh"
configure_tempest_for_aodh
fi
if [[ "$1" == "unstack" ]]; then