Sha256: 7dfea0617c9133666fac35e8f801730b5664b2bdf8e8922c25164bb7b59957e9
Contents?: true
Size: 883 Bytes
Versions: 3
Compression:
Stored size: 883 Bytes
Contents
# encoding: utf-8 require "spec_helper" describe Vkontakte::Api::Profile do it "should be valid" do Vkontakte::Api::Profile.should be_a(Module) end context "params" do before(:each) do @token = '7a1cfdd37a3b72167a3b7216ac7a1347bde7a3b7a3a7216c95a735a210be6d4' @user = Vkontakte::App::User.new('2592709', :access_token => @token) response = '{"response":[{"uid":2592709, "last_name":"Галета", "first_name":"Павел"}]}' FakeWeb.register_uri(:get, "https://api.vk.com/method/users.get?uids=2592709&access_token=#{@token}", :body => response) end it "should be call users.get method" do @user.fetch.should_not be_blank end it "should have info in parsed_reponse" do @user.fetch.should eq [{"uid" => 2592709, "last_name" => "Галета", "first_name" => "Павел"}] end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
vkontakte-0.0.5 | spec/api/profile_spec.rb |
vkontakte-0.0.4 | spec/api/profile_spec.rb |
vkontakte-0.0.3 | spec/api/profile_spec.rb |