-
Notifications
You must be signed in to change notification settings - Fork 45
Closed
Labels
comp-codegenIssue is related to code generatorIssue is related to code generatorcomp-springIssue is related to Spring projects supportIssue is related to Spring projects supportctg-enhancementNew feature, improvement or change requestNew feature, improvement or change request
Milestone
Description
Description
Try to generate unit or integration tests for an arbitrary Spring project.
All class fields, annotated with @InjectMocks, @Mock, @Autowired, or mockitoCloseable field are now public.
Example:
In accordance with Mockito documentation, we should (https://javadoc.io/static/org.mockito/mockito-core/3.5.6/org/mockito/MockitoAnnotations.html)
- Make
@InjectMock,@Mockand@Autowiredfields private - Make
mockitoCloseablevariable private - Still use public for
setUpandtearDownmethods.
Also it is better to locate setUp and tearDown under test methods, not above them.
Metadata
Metadata
Assignees
Labels
comp-codegenIssue is related to code generatorIssue is related to code generatorcomp-springIssue is related to Spring projects supportIssue is related to Spring projects supportctg-enhancementNew feature, improvement or change requestNew feature, improvement or change request
Type
Projects
Status
Done
