Sha256: b116785120ccc3e33a6aed8084033bca646d4b89fa80b89731c6b1ee11d78466

Contents?: true

Size: 501 Bytes

Versions: 9

Compression:

Stored size: 501 Bytes

Contents

class Zendesk2::Client
  class Real
    def destroy_topic(params={})
      id = params["id"]

      request(
        :method => :delete,
        :path   => "/topics/#{id}.json"
      )
    end
  end

  class Mock
    def destroy_topic(params={})
      id   = params["id"]
      path = "/topics/#{id}.json"

      body = self.delete!(:topics, id)

      response(
        :method => :delete,
        :path   => path,
        :body   => {
          "topic" => body,
        },
      )
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
zendesk2-1.4.2 lib/zendesk2/client/requests/destroy_topic.rb
zendesk2-1.4.1 lib/zendesk2/client/requests/destroy_topic.rb
zendesk2-1.4.0 lib/zendesk2/client/requests/destroy_topic.rb
zendesk2-1.3.3 lib/zendesk2/client/requests/destroy_topic.rb
zendesk2-1.3.2 lib/zendesk2/client/requests/destroy_topic.rb
zendesk2-1.3.1 lib/zendesk2/client/requests/destroy_topic.rb
zendesk2-1.3.0 lib/zendesk2/client/requests/destroy_topic.rb
zendesk2-1.2.10 lib/zendesk2/client/requests/destroy_topic.rb
zendesk2-1.2.9 lib/zendesk2/client/requests/destroy_topic.rb