Sha256: a9f710a54a19754bd21570194a8814b1f673dd59d69a53e1858bf3658830eb7a

Contents?: true

Size: 364 Bytes

Versions: 2

Compression:

Stored size: 364 Bytes

Contents

# frozen_string_literal: true

require "test_helper"

class ResourceTest < Minitest::Test
  def test_handle_response_error
    error_code = Calendlyr::Resource::ERROR_CODES.sample
    stub(path: "users/me", response: {body: fixture_file("resources/#{error_code}"), status: error_code.to_i})

    assert_raises Calendlyr::Error do
      client.me
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
calendlyr-0.6.0 test/calendlyr/resource_test.rb
calendlyr-0.5.0 test/calendlyr/resource_test.rb