Sha256: 56ca52e43992e097235f3fad2237d5a80a33f15586aea09cfd408859703c05e8
Contents?: true
Size: 885 Bytes
Versions: 7
Compression:
Stored size: 885 Bytes
Contents
require File.dirname(__FILE__) + '/../test_helper' class TollFreePhoneNumberTest < Test::Unit::TestCase #:nodoc: all context "A toll free phone number" do setup do @connection = Twilio::Connection.new('mysid', 'mytoken') @toll_free = Twilio::TollFreePhoneNumber.new(@connection) end should "be retrievable as a list" do fake_response = fixture(:incoming_phone_numbers) FakeWeb.register_uri(:get, twilio_url('IncomingPhoneNumbers/TollFree'), :string => fake_response) assert_equal @toll_free.list, fake_response end should "be created" do fake_response = fixture(:incoming_phone_number) FakeWeb.register_uri(:post, twilio_url('IncomingPhoneNumbers/TollFree'), :string => fake_response) response = @toll_free.create('http://test.local/call_handler') assert_equal response, fake_response end end end
Version data entries
7 entries across 7 versions & 2 rubygems