org.testng.TestNGException: Cannot inject @Test annotated Method [f] with [interface java.util.Map]. For more information on native dependency injection please refer to

Skip to first unread message

Vaishnavi Dontha

Oct 10, 2022, 10:30:00 PM10/10/22
to testng-users

I am having a problem to pass Object[] as parameter in @BeforeMethod and use the same in @Test method. 

Throws error as DependencyInjection Error

⇜Krishnan Mahadevan⇝

Oct 10, 2022, 10:31:31 PM10/10/22
Short answer: You cant do it. 

Can you please elaborate what are you trying to do along with some code snippets?

You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To view this discussion on the web visit
Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @
My Technical Scribblings @
Reply all
Reply to author
0 new messages