### Question:
OpushConfigurationImpl implements OpushConfiguration { @Override public String getActiveSyncServletUrl() { String externalUrl = getExternalUrl(); if (externalUrl == null) { throw new InvalidConfigurationEntry(EXTERNAL_URL_KEY); } return "https: } @VisibleForTesting protected  OpushConfigurationImpl(IniFile opushConfigurationFile, String applicationName); @Override Charset getDefaultEncoding(); @Override String getDataDirectory(); @Override int transactionTimeoutInSeconds(); @Override ResourceBundle getResourceBundle(Locale locale); @Override String getGlobalDomain(); @Override String getActiveSyncServletUrl(); @Override boolean isRequestLoggerEnabled(); @Override String getObmSyncBaseUrl(String obmSyncHost); @Override String getObmSyncServicesUrl(String obmSyncHost); @Override int defaultWindowSize(); @Override Optional<Integer> maxWindowSize();  }### Answer:
@Test public void testGetActiveSyncServletUrl() { String externalUrl = "10.69.1.23"; expect(iniFile.getStringValue(OpushConfigurationImpl.EXTERNAL_URL_KEY)) .andReturn(externalUrl); control.replay(); String activeSyncServletUrl = opushConfigurationImpl.getActiveSyncServletUrl(); control.verify(); assertThat(activeSyncServletUrl).isEqualTo("https: }
@Test(expected=InvalidConfigurationEntry.class) public void testGetActiveSyncServletUrlNullExternalUrl() { expect(iniFile.getStringValue(OpushConfigurationImpl.EXTERNAL_URL_KEY)) .andReturn(null); control.replay(); try { opushConfigurationImpl.getActiveSyncServletUrl(); } catch (InvalidConfigurationEntry e) { control.verify(); throw e; } }