spec/api/user_spec.rb in triviacrack-0.4.0 vs spec/api/user_spec.rb in triviacrack-0.5.0
- old
+ new
@@ -3,12 +3,12 @@
describe TriviaCrack::API::User do
let(:session) { TriviaCrack::Session.new session_id: "session", user_id: 1 }
let(:client) { (Class.new(APIStub) { include TriviaCrack::API::User }).new session }
- let(:response) { double(code: code, body: raw_data) }
+ let(:response) { double(status: code, body: raw_data) }
- before { allow(Unirest).to receive(:get) { response } }
+ before { allow(Faraday).to receive(:get) { response } }
describe "#get_user_id" do
let(:username) { "example.2" }
subject { client.get_user_id username }