Categories dependency-injection

7 posts

Auto Added by WPeMatico

Fragment Espresso Testing With Dagger’s Android Injector

A few months ago I have written about how to test Activity that uses Dagger’s AndroidInjector in an Espresso test. The solution worked well for an Activities but if you’re using Fragments, this might add additional complexity, as always, and we need to refine the solution in order to test […]

Java libraries with Kotlin. The case of dependency injection frameworks

https://www.flickr.com/photos/the-money-pit/5900474232 Kotlin opened up a new world for us. Developers write less code than before in Java world. And Kotlin’s interoperability with Java made it easy to incorporate it into existing and new apps, while still having the freedom of using our favourite Java libraries. However, as these libraries are […]

Modern Android development with Kotlin Part 4

It is really hard to find one project that covers all the things that are new in Android Development, so I decided to write one. 0. Android Studio 3 Part 11. Kotlin language Part 12. Build Variants Part 13. ConstraintLayout Part 14. Data binding library Part 15. MVVM architecture + repository […]

Dependency Injection (DI) Container in PHP

https://pixabay.com/en/container-crane-port-transport-1574239/ Introduction We have introduced Introduction to PHP Reflection API, clarifying what is Reflection API, and what is the different purposes of it, one of these -and most common- is using it with the DI Container, here is the article agenda: What is Dependency Injection. Different Ways of Injecting Objects (and Why?). […]

Dagger 2 for Android Beginners — Dagger 2 part II

This story is the fifth part of the series, Dagger 2 for Android Beginners. If you did not read the previous one, you can start from below. Dagger 2 for Android Beginners — Introduction Series Pitstops Dagger 2 for Android Beginners — Introduction Dagger 2 for Android Beginners — DI part I Dagger 2 for Android […]

Dagger 2 for Android Beginners — Introduction

Dagger is a fully static, compile-time dependency injection framework for both Java and Android. It is an adaptation of an earlier version created by Square and now maintained by Google. (source) Who should read? If you’re a budding Android developer, who started with Android directly and learning Java parallely — this is for you. […]

You don’t need to know “Dependency Injection”

I’ve recently been party to an interview for a front-end position where a colleague asked the candidate — “What do you know about Dependency Injection?”. I had a feeling this may have been a “gotcha” question, but at the time couldn’t quite articulate why. We’ve since had some time to discuss and […]