alibaba / alibaba/testable-mock

springboot框架下拦截器中的方法怎么修改

Open
#332 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
1.8k
Forks
306
PR merge metrics
No merged PRs in 30d

Description

我在单元测试里直接请求接口,因为拦截器校验登录信息,我想让方法直接返回true,但是修改该方法无效,不知道该怎么改

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the unit-test request described in the issue and inspect the Spring Boot interceptor involved in login validation. Determine why changing the interceptor method does not affect the test request; done means the request can bypass the login check in the unit-test scenario and the behavior is covered by a test.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring-boot
Domain
backend, testing
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.