alibaba / alibaba/testable-mock

静态代码块

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

Description

比如:连接一个redis,采用是静态代码块的方式。测试的时候是否能屏蔽了?不然每次测试该类都要加载连接

Contributor guide

No contributing guide indexed for this repository

Research direction

No source file, test, or entry point is identified. Start by tracing how testable-mock runs Java tests and initializes classes, focusing on whether static initialization can be intercepted or disabled. Done means tests can prevent a static Redis connection from loading without breaking normal class behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, redis
Domain
testing
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.