From 9fe7820864a9f7dd65af9660d2b6250e16d1a2a7 Mon Sep 17 00:00:00 2001 From: Rabi Mishra Date: Fri, 1 Feb 2019 22:11:30 +0530 Subject: [PATCH] Fix test_server_software_config scenario test In commit 4ca172ae78bc606b02150b07776b695f1b3a6678 we changed to use heatclient utilities to load files and it broke this test. File mode must be string from Puppet 4 onwards, so the inline manifest also needs to be fixed. Note: This test is not run in the gate. Change-Id: Ia0be1aab36448b291ea43371a5d906fa79eb3753 --- .../scenario/templates/test_server_software_config.yaml | 4 ++-- .../tests/scenario/test_server_software_config.py | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/heat_tempest_plugin/tests/scenario/templates/test_server_software_config.yaml b/heat_tempest_plugin/tests/scenario/templates/test_server_software_config.yaml index bf8fa9b..9df6532 100644 --- a/heat_tempest_plugin/tests/scenario/templates/test_server_software_config.yaml +++ b/heat_tempest_plugin/tests/scenario/templates/test_server_software_config.yaml @@ -52,7 +52,7 @@ resources: - name: bar outputs: - name: result - config: {get_file: cfg1.sh} + config: {get_file: /cfg1.sh} cfg2a: type: OS::Heat::StructuredConfig @@ -87,7 +87,7 @@ resources: - name: bar outputs: - name: result - config: {get_file: cfg3.pp} + config: {get_file: /cfg3.pp} dep1: type: OS::Heat::SoftwareDeployment diff --git a/heat_tempest_plugin/tests/scenario/test_server_software_config.py b/heat_tempest_plugin/tests/scenario/test_server_software_config.py index 4d2f7dc..7da2853 100644 --- a/heat_tempest_plugin/tests/scenario/test_server_software_config.py +++ b/heat_tempest_plugin/tests/scenario/test_server_software_config.py @@ -27,14 +27,14 @@ echo "Output to stderr" 1>&2 CFG3_PP = '''file {'barfile': ensure => file, - mode => 0644, + mode => '0644', path => "/tmp/$::bar", content => "$::foo", } file {'output_result': ensure => file, path => "$::heat_outputs_path.result", - mode => 0644, + mode => '0644', content => "The file /tmp/$::bar contains $::foo for server \ $::deploy_server_id during $::deploy_action", } @@ -153,8 +153,8 @@ class SoftwareConfigIntegrationTest(scenario_base.ScenarioTestsBase): } files = { - 'cfg1.sh': CFG1_SH, - 'cfg3.pp': CFG3_PP + 'file:///cfg1.sh': CFG1_SH, + 'file:///cfg3.pp': CFG3_PP } env_files, env = template_utils.process_environment_and_files(