Giter VIP home page Giter VIP logo

sohu_interview's Introduction

手机搜狐机试题

本项目旨在完成手机搜狐提供的机试题。

题目描述

请实现 微信公众平台网页授权获取用户基本信息 功能,要求:

  1. 授权后展示用户的详细信息
  2. 提供 github 提交历史
  3. 公众号的二维码,测试 URL

功能

实现的功能如下:

  1. 获取用户授权,并在回调中异步查询用户信息
  2. 提供接口用于展示用户自己的信息
  3. (未实现) 主动刷新 access_token

使用

  1. 微信扫描二维码,关注测试公众号

doc_image/92721b212421b73adb8a643aa51ae08d.jpg

  1. 在微信中点击下面的链接,同意授权后,点击链接获取用户信息

http://123.57.235.88/userInfo/

PS: 微信可能会弹出如下提示,可能需要多点几次才会弹出实际页面。

doc_image/b91a6e424013456729786aaa09ec4f35.jpg

测试记录

功能测试的过程记录在此:

  • [x] 访问 userAuthorization

    • [x] 携带有效 code,刷新session,更新用户信息,引导至 userInfo
    • [x] 携带无效 code,刷新session,引导至 userInfo
    • [x] 未携带 code,错误提示
  • [x] 访问 userInfo

    • [x] 用户未授权或授权已失效,重定向至授权页面
    • [x] 存在对应用户信息,展示用户信息
    • [x] 不存在对应用户信息,引导至授权页面
  • [ ] wxgz.tasks.request_user_info_by_code_asy 异步正确

sohu_interview's People

Contributors

wangergou avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.