'Tests resource replacing when changing non-updatable properties.'

def test_mem_alarm_high_update_replace(self):

    t = template_format.parse(alarm_template)
    properties = t['Resources']['MEMAlarmHigh']['Properties']
    properties['alarm_actions'] = ['signal_handler']
    properties['matching_metadata'] = {'a': 'v'}
    test_stack = self.create_stack(template=json.dumps(t))
    test_stack.create()
    rsrc = test_stack['MEMAlarmHigh']
    properties = copy.copy(rsrc.properties.data)
    properties['meter_name'] = 'temp'
    snippet = rsrc_defn.ResourceDefinition(rsrc.name, rsrc.type(), properties)
    updater = scheduler.TaskRunner(rsrc.update, snippet)
    self.assertRaises(resource.UpdateReplace, updater)
