'Test that backup does not start for failed resource.'

def test_snapshot_no_volume(self):

    stack_name = 'test_volume_snapshot_novol_stack'
    cfg.CONF.set_override('action_retry_limit', 0)
    fv = self._mock_create_volume(vt_base.FakeVolume('creating'), stack_name, final_status='error')
    self._mock_delete_volume(fv)
    self.m.ReplayAll()
    self.t['Resources']['DataVolume']['DeletionPolicy'] = 'Snapshot'
    self.t['Resources']['DataVolume']['Properties']['AvailabilityZone'] = 'nova'
    stack = utils.parse_stack(self.t, stack_name=stack_name)
    resource_defns = stack.t.resource_definitions(stack)
    rsrc = aws_vol.Volume('DataVolume', resource_defns['DataVolume'], stack)
    create = scheduler.TaskRunner(rsrc.create)
    ex = self.assertRaises(exception.ResourceFailure, create)
    self.assertIn('Went    to    status    error    due    to    "Unknown"', six.text_type(ex))
    scheduler.TaskRunner(rsrc.destroy)()
    self.m.VerifyAll()
