From 960892eec3d1696442983a7ce432f01b5b1953ac Mon Sep 17 00:00:00 2001 From: "yadong.zhang" Date: Sat, 15 Aug 2020 20:44:43 +0800 Subject: [PATCH] :white_check_mark: Adding tests. --- .../request/AuthWeChatMpRequestTest.java | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 src/test/java/me/zhyd/oauth/request/AuthWeChatMpRequestTest.java diff --git a/src/test/java/me/zhyd/oauth/request/AuthWeChatMpRequestTest.java b/src/test/java/me/zhyd/oauth/request/AuthWeChatMpRequestTest.java new file mode 100644 index 0000000..1fd144a --- /dev/null +++ b/src/test/java/me/zhyd/oauth/request/AuthWeChatMpRequestTest.java @@ -0,0 +1,19 @@ +package me.zhyd.oauth.request; + +import me.zhyd.oauth.config.AuthConfig; +import me.zhyd.oauth.utils.AuthStateUtils; +import org.junit.Test; + +public class AuthWeChatMpRequestTest { + + @Test + public void authorize() { + + AuthRequest request = new AuthWeChatMpRequest(AuthConfig.builder() + .clientId("a") + .clientSecret("a") + .redirectUri("https://www.justauth.cn") + .build()); + System.out.println(request.authorize(AuthStateUtils.createState())); + } +} -- GitLab