My actual method signature is:
public List<T> readFileToMemory(FooFile fooFile, **Class<T> entityClass**) { } and I am trying to mock this as:
when(mockObject.readFileToMemory(any(FooFile.class), Matchers.any(Class<Bar>)).thenReturn(new ArrayList<Bar>()) but second argument doesn't compile. How to fix it?
I referred to the following answers but still no luck.