Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Marcin Grzejszczak
@marcingrzejszczak
Marcin Grzejszczak
@marcingrzejszczak
@all - since version 1.1.0 the extension is available also at Maven Central! Enjoy :)
Ashish Meshram
@ashishjmeshram
Hi
Marcin Grzejszczak
@marcingrzejszczak
hello
Ashish Meshram
@ashishjmeshram
so I know constructor injection will work
But is there any way I can this work?
Marcin Grzejszczak
@marcingrzejszczak
of course
show me the two other classes
and I'll see what I can do about this ;)
Ashish Meshram
@ashishjmeshram
is there any way to upload files here ?
Marcin Grzejszczak
@marcingrzejszczak
yeah you can drag and drop
you can also paste them
you can use markdown
Ashish Meshram
@ashishjmeshram
Oh Okay
Marcin Grzejszczak
@marcingrzejszczak
GenericDAOImpl too please
Ashish Meshram
@ashishjmeshram
Here you go !
Marcin Grzejszczak
@marcingrzejszczak
ok thx
Ashish Meshram
@ashishjmeshram
I really appreciate you trying to help me out here
Marcin Grzejszczak
@marcingrzejszczak
np - give me a sec - I'll write a test
Ashish Meshram
@ashishjmeshram
sure
Marcin Grzejszczak
@marcingrzejszczak
what's this
make(a(UserMaker.User));
it's just some builder for User ?
Ashish Meshram
@ashishjmeshram
yep
It just creates a default user.
Marcin Grzejszczak
@marcingrzejszczak
ok I've reproduced it
Ashish Meshram
@ashishjmeshram
Okay
any idea on what is the issue here ?
Marcin Grzejszczak
@marcingrzejszczak
yeah actually I do
you're mixing unit and integration tests
you want my lib to construct a new instance of an interface
interface don't have constructors
so I can't just initialize it
if you change the UserService to UserServiceImpl it should work
Ashish Meshram
@ashishjmeshram
ohh
Ohh yes Now it worked
But is that ok
?
Marcin Grzejszczak
@marcingrzejszczak
yes
Ashish Meshram
@ashishjmeshram
I mean this way ?
Marcin Grzejszczak
@marcingrzejszczak
beacuse my lib is for unit testing
Ashish Meshram
@ashishjmeshram
@Subject
UserServiceImpl userService
Marcin Grzejszczak
@marcingrzejszczak
I can't autowire your field - I'm not using Spring
Ashish Meshram
@ashishjmeshram
I am doing unit testing only
which is why I want to mock them