Sha256: 4a04663eeb3b716bc6760571aadb8834e9abee1b7c18c6dec204ffa73e0ec27b
Contents?: true
Size: 874 Bytes
Versions: 2
Compression:
Stored size: 874 Bytes
Contents
require 'spec_helper' describe WhitePages do context "Valid API Key" do it "should find a person" do WhitePages.find_person(name: 'John Doe').should be_an_instance_of(Hashie::Mash) end it "should find a business" do WhitePages.find_business(businessname: 'Target').should be_an_instance_of(Hashie::Mash) end it "should reverse a phone number" do WhitePages.reverse_phone(phone: '3236030004').should be_an_instance_of(Hashie::Mash) end it "should reverse an address" do WhitePages.reverse_address(street: 'Santa Monica Blvd').should be_an_instance_of(Hashie::Mash) end end context "Invalid API Key" do it "should raise errors" do WhitePages.api_key = 'invalid' lambda { WhitePages.find_person(name: 'John Doe') }.should raise_error(WhitePages::WhitePagesError) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
white_pages-0.0.2 | spec/white_pages_spec.rb |
white_pages-0.0.1 | spec/white_pages_spec.rb |