Sha256: afda57373bcfeeaee5ab0c1d6130317710cbaf0f4966a4438679b4f0388b4993

Contents?: true

Size: 597 Bytes

Versions: 4

Compression:

Stored size: 597 Bytes

Contents

# frozen_string_literal: true
module Fog
  module Orchestration
    class HuaweiCloud
      class Real
        def cancel_update(stack)
          request(
            :expects => 200,
            :method  => 'POST',
            :path    => "stacks/#{stack.stack_name}/#{stack.id}/actions",
            :body    => Fog::JSON.encode('cancel_update' => nil)
          )
        end
      end

      class Mock
        def cancel_update(_)
          response = Excon::Response.new
          response.status = 200
          response.body = {}
          response
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
fog-huaweicloud-0.0.3 lib/fog/orchestration/huaweicloud/requests/cancel_update.rb
fog-huaweicloud-0.0.2 lib/fog/orchestration/huaweicloud/requests/cancel_update.rb
fog-huaweicloud-0.1.3 lib/fog/orchestration/huaweicloud/requests/cancel_update.rb
fog-huaweicloud-0.1.2 lib/fog/orchestration/huaweicloud/requests/cancel_update.rb