Commit d3e28ff1 by lanrion

fixed test and clean codes

parent 2124121e
......@@ -33,9 +33,6 @@ module WeixinAuthorize
WeixinAuthorize.http_get_without_token("/sns/userinfo?access_token=#{oauth_token}&openid=#{openid}&lang=#{lang}", {}, "api")
end
private
end
end
end
......@@ -5,14 +5,14 @@ describe WeixinAuthorize::Api::Qrcode do
it "#create_qr_scene" do
response = $client.create_qr_scene("123")
expect(response.code).to eq(WeixinAuthorize::OK_CODE)
expect(response.result.keys).to eq(["ticket", "expire_seconds"])
expect(response.result.keys).to eq(["ticket", "expire_seconds", "url"])
expect(response.result["expire_seconds"]).to eq(1800)
end
it "#create_qr_limit_scene" do
response = $client.create_qr_limit_scene("1234")
expect(response.code).to eq(WeixinAuthorize::OK_CODE)
expect(response.result.keys).to eq(["ticket"])
expect(response.result.keys).to eq(["ticket", "url"])
end
it "#return_qr_url" do
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment