zed
5 years ago
3 changed files with 79 additions and 0 deletions
@ -0,0 +1,30 @@
|
||||
package com.fanruan.api.decision; |
||||
|
||||
import org.junit.Assert; |
||||
import org.junit.Test; |
||||
|
||||
import java.lang.reflect.Method; |
||||
|
||||
/** |
||||
* @author Zed |
||||
* @version 10.0 |
||||
* Created by Zed on 2020/4/30 |
||||
*/ |
||||
public class AuthorityKitTest { |
||||
|
||||
@Test |
||||
public void setAuth() throws Exception { |
||||
|
||||
Class<?> classBook = Class.forName("com.fanruan.api.decision.AuthorityKit"); |
||||
Assert.assertNotNull(classBook); |
||||
|
||||
Method method1 = classBook.getDeclaredMethod("setCustomRoleAuth", String.class, int.class, String.class, int.class); |
||||
Assert.assertNotNull(method1); |
||||
|
||||
Method method2 = classBook.getDeclaredMethod("setUserAuth", String.class, int.class, String.class, int.class); |
||||
Assert.assertNotNull(method2); |
||||
|
||||
Method method3 = classBook.getDeclaredMethod("setDepAuth", String.class, int.class, String.class, int.class); |
||||
Assert.assertNotNull(method3); |
||||
} |
||||
} |
@ -0,0 +1,24 @@
|
||||
package com.fanruan.api.decision.role; |
||||
|
||||
import org.junit.Assert; |
||||
import org.junit.Test; |
||||
|
||||
import java.lang.reflect.Method; |
||||
|
||||
/** |
||||
* @author Zed |
||||
* @version 10.0 |
||||
* Created by Zed on 2020/4/30 |
||||
*/ |
||||
public class CustomRoleKitTest { |
||||
|
||||
@Test |
||||
public void getCustomRoleIds() throws Exception { |
||||
|
||||
Class<?> classBook = Class.forName("com.fanruan.api.decision.role.CustomRoleKit"); |
||||
Assert.assertNotNull(classBook); |
||||
|
||||
Method method1 = classBook.getDeclaredMethod("getCustomRoleIds", String.class, String.class); |
||||
Assert.assertNotNull(method1); |
||||
} |
||||
} |
@ -0,0 +1,25 @@
|
||||
package com.fanruan.api.decision.user; |
||||
|
||||
import org.junit.Assert; |
||||
import org.junit.Test; |
||||
|
||||
import javax.servlet.http.HttpServletRequest; |
||||
import java.lang.reflect.Method; |
||||
|
||||
/** |
||||
* @author Zed |
||||
* @version 10.0 |
||||
* Created by Zed on 2020/4/30 |
||||
*/ |
||||
public class UserKitTest { |
||||
|
||||
@Test |
||||
public void getCurrentUserId() throws Exception { |
||||
|
||||
Class<?> classBook = Class.forName("com.fanruan.api.decision.user.UserKit"); |
||||
Assert.assertNotNull(classBook); |
||||
|
||||
Method method1 = classBook.getDeclaredMethod("getCurrentUserId", HttpServletRequest.class); |
||||
Assert.assertNotNull(method1); |
||||
} |
||||
} |
Loading…
Reference in new issue