java - Mocked private method getting invocked Jmockito -


i writing test case class using mockito , power mockito. 1 of public method wrote test case internally calling private method, dont care result of private method decided mock method using power mockito below

powermockito.doreturn(refdatalistvo).when(mockobject,             "referencedatavalues",mockito.anylist(),(referencedatalistvo)anyobject()); 

my referencedatavalues method below

private referencedatalistvo referencedatavalues(list inputlist,             referencedatalistvo referencedatalistvo) {    // code } 

but when run code referencedatavalues method getting invoked.

please me on this


Comments

Popular posts from this blog

google api - Incomplete response from Gmail API threads.list -

Installing Android SQLite Asset Helper -

Qt Creator - Searching files with Locator including folder -