@Test(expected = VersionNotFoundException.class) public void invalidFindVersion() throws IOException, VersionNotFoundException { loadFakeVersions(200, true); client.findVersion(null); }
HockeyAppVersion findVersion(String shortVersion) throws VersionNotFoundException, IOException { if (shortVersion == null || shortVersion.isEmpty()) { throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); } if (versions == null) { versions = getVersions(); } for (HockeyAppVersion version : versions) { if (shortVersion.equals(version.shortVersion)) { return version; } } throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); }
VersionClient { HockeyAppVersion findVersion(String shortVersion) throws VersionNotFoundException, IOException { if (shortVersion == null || shortVersion.isEmpty()) { throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); } if (versions == null) { versions = getVersions(); } for (HockeyAppVersion version : versions) { if (shortVersion.equals(version.shortVersion)) { return version; } } throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); } }
VersionClient { HockeyAppVersion findVersion(String shortVersion) throws VersionNotFoundException, IOException { if (shortVersion == null || shortVersion.isEmpty()) { throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); } if (versions == null) { versions = getVersions(); } for (HockeyAppVersion version : versions) { if (shortVersion.equals(version.shortVersion)) { return version; } } throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); } VersionClient(HockeyAppRequestBuilder requestBuilder); }
VersionClient { HockeyAppVersion findVersion(String shortVersion) throws VersionNotFoundException, IOException { if (shortVersion == null || shortVersion.isEmpty()) { throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); } if (versions == null) { versions = getVersions(); } for (HockeyAppVersion version : versions) { if (shortVersion.equals(version.shortVersion)) { return version; } } throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); } VersionClient(HockeyAppRequestBuilder requestBuilder); HockeyAppVersion getVersion(); }
VersionClient { HockeyAppVersion findVersion(String shortVersion) throws VersionNotFoundException, IOException { if (shortVersion == null || shortVersion.isEmpty()) { throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); } if (versions == null) { versions = getVersions(); } for (HockeyAppVersion version : versions) { if (shortVersion.equals(version.shortVersion)) { return version; } } throw new VersionNotFoundException("Version: " + shortVersion + " not found!"); } VersionClient(HockeyAppRequestBuilder requestBuilder); HockeyAppVersion getVersion();  }