VersionManagerImpl implements VersionManager { @Override public void updateRemoteReleaseInfo() { releaseDao.updateRelease(HOLMES_GITHUB_RELEASE_API_URL.toString()); } @Inject  VersionManagerImpl(final ReleaseDao releaseDao, @Named("currentVersion") final String currentVersion); @Override String getCurrentVersion(); @Override ReleaseInfo getRemoteReleaseInfo(); @Override void updateRemoteReleaseInfo();  }
@Test public void testUpdateRemoteReleaseInfo() { ReleaseDao releaseDao = createMock(ReleaseDao.class); releaseDao.updateRelease(isA(String.class)); expectLastCall(); replay(releaseDao); VersionManagerImpl versionManager = new VersionManagerImpl(releaseDao, "0.6.3"); versionManager.updateRemoteReleaseInfo(); verify(releaseDao); }