samuel34
(Samuel Male)
June 11, 2018, 1:12pm
21
@dkayiwa I don’t really know whats really going on hear but even when I do it out of the constructor, its actually the same thing. And btw, for sync2, it actually creates it from the constructor
cc: https://github.com/openmrs/openmrs-module-sync2/blob/master/api/src/main/java/org/openmrs/module/sync2/api/impl/SyncConfigurationServiceImpl.java#L37
dkayiwa
(Daniel Kayiwa)
June 11, 2018, 2:21pm
23
The bean in sync is instantiated differently from yours. When you took it out of the constructor, where did you put it?
samuel34
(Samuel Male)
June 11, 2018, 9:19pm
24
I’m failing to understand how different it is. And which bean to be specific @dkayiwa
dkayiwa:
where did you put it?
dkayiwa
(Daniel Kayiwa)
June 11, 2018, 10:19pm
25
Did you try doing what i told you? That is, not calling that method from the constructor?
samuel34
(Samuel Male)
June 12, 2018, 3:40pm
26
dkayiwa
(Daniel Kayiwa)
June 12, 2018, 7:28pm
27
If you are calling this from a unit test, then you need to use what @mseaton told you.
samuel34
(Samuel Male)
June 12, 2018, 9:53pm
28
Looks like I didn’t understand @mseaton ’s advice but at a fifth glance, I atlast understood him. Cool am now good thanks @dkayiwa