# Guice and JUnit

DevFeed: [Guice and JUnit](<https://devfeed.tech/articles/guice-and-junit-37769.md>)

Original publisher: [Read original article](<https://carlosbecker.com/posts/guice-and-junit/>)

Author: Carlos Alexandro Becker

Published: 2012-08-06T00:00:00Z

Content type: tutorial

Language: en

Sources: [Carlos Becker](<https://devfeed.tech/sources/carlos-becker.md>)

Topics: [Dependency injection](<https://devfeed.tech/topics/dependency-injection.md>), [container](<https://devfeed.tech/topics/container.md>), [Java](<https://devfeed.tech/topics/java.md>), [test](<https://devfeed.tech/topics/test.md>), [Google](<https://devfeed.tech/topics/google.md>)

Tags: [dependency-injection](<https://devfeed.tech/tags/dependency-injection.md>), [google](<https://devfeed.tech/tags/google.md>), [java](<https://devfeed.tech/tags/java.md>), [test](<https://devfeed.tech/tags/test.md>), [tests](<https://devfeed.tech/tags/tests.md>)

## AI overview

This article discusses testing applications that use Guice for dependency injection. It describes the difficulty of testing generic injected components and introduces a simple library intended to work with JUnit 4.10 without additional frameworks such as Mockito; the author says it had not yet been published.

## Source excerpt

First of all: Do you use Guice as Dependency Injection Container in your Apps? If not, why?