Created
June 1, 2018 18:12
-
-
Save CollectiveHealth-gists/7098eff1e02ce03bd2c0a0a62abb613a to your computer and use it in GitHub Desktop.
Testing with real instance of DisplaySystem, but mocked out SoundSystem.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class IntegrationWithDisplaySystemTest { | |
@Test | |
public void testDisplaySystem() { | |
Injector injector = Guice.createInjector(new ComputerTestModule() | |
.withInstance(DisplaySystem.class, new DisplaySystem())); | |
Computer computer = injector.getInstance(Computer.class); | |
// We are satisfied with no exception being thrown | |
computer.showDesktop(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment