SURYAS1306 commented on PR #12615: URL: https://github.com/apache/cloudstack/pull/12615#issuecomment-3886569125
Hi @DaanHoogland, I'm still seeing persistent NotMock errors in AccountManagerImplTest. All failures point to: AccountManagerImplTest.beforeTest:164 NotMock Argument passed to when() is not a mock So far I’ve: - Added the missing _projectDao mock - Updated usages to match production field names - Fixed the accountManager → accountManagerImpl typo - Added Mockito.spy(accountManagerImpl) in setUp() I suspect this might be due to: - Having two @Before methods with no guaranteed execution order - Or possibly overwriting mocks inside setUp() with manual Mockito.mock() calls Would you recommend consolidating the @Before methods into one, or removing the manual Mockito.mock() calls and relying only on @Mock annotations? Since this test extends AccountManagetImplTestBase, I want to ensure I’m aligning with the existing pattern. I’ll update based on your feedback. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
