Clean Architecture on Android |

This is a companion discussion topic for the original entry at

Hi, thanks for the talk, it was amazing I learned a lot.
Regarding the fetching, I was following the tutorial but I got an error when UnitTesting the JupiterFetch, what I figured out was that the fetchJupiter() method should be run on the init section in order to get a SUCCESS state, what I want to know, is why it happened! By the way… I think it could also be solved with a coroutine, if I don’t want to run it in the init section (also, could you please tell me what should go into the init section and what no) Thanks in advance.

I got another question, I know this example was based on the bufferapp, but when it comes to starting a new real project, what would be the module you designed and coded first?

@macsimus Can you please help with this when you get a chance? Thank you - much appreciated! :]

Hi @jessie.lorena, thank you for the comments and questions! I’ll have to check out the JupiterFetch question when I can. But trying out a coroutine sounds cool!

The init block is used to add code needed to initialize an instance, since the entire instance must be initialized and the primary constructor cannot contain code.

In terms of a real project, for Clean Architecture my personal approach would be to start in the core and work your way outward. Inner layers are independent of outer layers, so you can unit test as you work your way outwards. But there are certainly other approaches too, whatever makes the most sense for your project.

Thanks again!

1 Like

Thanks for sharing, it was very informative. I also found a helpful article that explains how to build an Android app following the main principles of Clean Android App Architecture but making it easy-to-understand at the same time: How to Build Android App Architecture (Cleveroad Experience)