freepascal / mockito

Automatically exported from code.google.com/p/mockito
0 stars 0 forks source link

bean is not returned. a null value is returned instead #42

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. invoke a method which returns a bean
2.
3.

What is the expected output? What do you see instead?
a mock bean should return

What version of the product are you using? On what operating system?
1.2 mockito

Please provide any additional information below.
stub(mock.somemethod("arg1", arg2, 0, 1, list1, list2)).toReturn(mockBean);

Original issue reported on code.google.com by shweta...@gmail.com on 16 Dec 2008 at 6:52

GoogleCodeExporter commented 9 years ago
It works fine for me. Could you show some more code? Do you create mockBean as a
mock? How do you validate what was returned?

By they way, I recommend to upgrade Mockito to the latest version.

Original comment by bbankow...@gmail.com on 16 Dec 2008 at 9:10

GoogleCodeExporter commented 9 years ago
this is how i created the bean..
mockBean= mock(classname.class);

Original comment by shweta...@gmail.com on 16 Dec 2008 at 9:36

GoogleCodeExporter commented 9 years ago
I've got the same in my code. Please, attach your test if you can as I still 
can't
reproduce the defect.

Original comment by bbankow...@gmail.com on 16 Dec 2008 at 10:21

GoogleCodeExporter commented 9 years ago
Closing this one as no further details were given and problem can't be 
reproduced.

Original comment by bbankow...@gmail.com on 9 Jan 2009 at 3:54

GoogleCodeExporter commented 9 years ago

Original comment by szcze...@gmail.com on 14 Jan 2009 at 10:48