Removes replace-on-update for SwiftSignalHandle resource
Rebuilding the resource on every stack update results in a new
url being generated. This causes any depending resources to
be rebuilt, even when there are no changes in the template.
Change-Id: Id385e0e8f9f68900b76a596a05ac99baceb831cc
Closes-Bug: #1473692
diff --git a/functional/test_swiftsignal_update.py b/functional/test_swiftsignal_update.py
new file mode 100644
index 0000000..0f1c43c
--- /dev/null
+++ b/functional/test_swiftsignal_update.py
@@ -0,0 +1,48 @@
+# Licensed under the Apache License, Version 2.0 (the "License"); you may
+# not use this file except in compliance with the License. You may obtain
+# a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+# License for the specific language governing permissions and limitations
+# under the License.
+
+
+from heat_integrationtests.common import test
+
+test_template = '''
+heat_template_version: 2014-10-16
+
+resources:
+ signal_handle:
+ type: "OS::Heat::SwiftSignalHandle"
+
+outputs:
+ signal_curl:
+ value: { get_attr: ['signal_handle', 'curl_cli'] }
+ description: Swift signal cURL
+
+ signal_url:
+ value: { get_attr: ['signal_handle', 'endpoint'] }
+ description: Swift signal URL
+'''
+
+
+class SwiftSignalHandleUpdateTest(test.HeatIntegrationTest):
+
+ def setUp(self):
+ super(SwiftSignalHandleUpdateTest, self).setUp()
+ self.client = self.orchestration_client
+
+ def test_stack_update_same_template_replace_no_url(self):
+ stack_identifier = self.stack_create(template=test_template)
+ stack = self.client.stacks.get(stack_identifier)
+ orig_url = self._stack_output(stack, 'signal_url')
+ orig_curl = self._stack_output(stack, 'signal_curl')
+ self.update_stack(stack_identifier, test_template)
+ stack = self.client.stacks.get(stack_identifier)
+ self.assertEqual(orig_url, self._stack_output(stack, 'signal_url'))
+ self.assertEqual(orig_curl, self._stack_output(stack, 'signal_curl'))