<kotlin.UninitializedPropertyAccessException: late...
# stackoverflow
u
kotlin.UninitializedPropertyAccessException: lateinit property has not been initialized This is my main function object Service { fun getConfigMappings(client: RedissonClient, request: GetRequest): IndataType { ** return obj } } I calling it in my main class, and everything works good, I can get the response. @Autowired lateinit var client: RedissonClient val indataObj = Service.getConfigMappings(client, request) When I want to write a test for it, I got error "kotlin.UninitializedPropertyAccessException: lateinit property client has not been...