@Test public void testVersionRetrieval() { String stableKey = "stable"; String devKey = "development"; String version = tdsContext.getVersionInfo(); Map<String, String> latestVersionInfo = tdsUpdateConfig.getLatestVersionInfo(version); assert (!latestVersionInfo.isEmpty()); assert (latestVersionInfo.containsKey(stableKey)); assert (!latestVersionInfo.get(stableKey).isEmpty()); assert (latestVersionInfo.containsKey(devKey)); assert (!latestVersionInfo.get(devKey).isEmpty()); }
public String getVersionInfo() { Formatter f = new Formatter(); f.format("%s", getWebappVersion()); if (getTdsVersionBuildDate() != null) { f.format(" - %s", getTdsVersionBuildDate()); } return f.toString(); }
TdsContext implements ServletContextAware, InitializingBean, DisposableBean { public String getVersionInfo() { Formatter f = new Formatter(); f.format("%s", getWebappVersion()); if (getTdsVersionBuildDate() != null) { f.format(" - %s", getTdsVersionBuildDate()); } return f.toString(); } }
TdsContext implements ServletContextAware, InitializingBean, DisposableBean { public String getVersionInfo() { Formatter f = new Formatter(); f.format("%s", getWebappVersion()); if (getTdsVersionBuildDate() != null) { f.format(" - %s", getTdsVersionBuildDate()); } return f.toString(); }  }
TdsContext implements ServletContextAware, InitializingBean, DisposableBean { public String getVersionInfo() { Formatter f = new Formatter(); f.format("%s", getWebappVersion()); if (getTdsVersionBuildDate() != null) { f.format(" - %s", getTdsVersionBuildDate()); } return f.toString(); }  @Override void setServletContext(ServletContext servletContext); ServletContext getServletContext(); @Override void destroy(); @Override void afterPropertiesSet(); @Override String toString(); String getContextPath(); String getWebappVersion(); String getTdsVersionBuildDate(); String getVersionInfo(); String getWebappDisplayName(); File getServletRootDirectory(); File getTomcatLogDirectory(); File getThreddsDirectory(); File getContentRootDir(); FileSource getPublicContentDirSource(); RequestDispatcher getDefaultRequestDispatcher(); String getContentRootPathProperty(); String getConfigFileProperty(); File getUploadDir(); File getDownloadDir(); File getUploadForm(); File getDownloadForm(); String getTdsDebugFlags(); void setContentRootPathProperty(String contentRootPathProperty); void setUploadDirProperty(String uploadDirProperty); void setDownloadDirProperty(String downloadDirProperty); void setUploadFormProperty(String uploadFormProperty); void setDownloadFormProperty(String downloadFormProperty); File getPropertyDir(String prop, String key, boolean create); File getPropertyFile(String prop, String key, boolean writeable); }
TdsContext implements ServletContextAware, InitializingBean, DisposableBean { public String getVersionInfo() { Formatter f = new Formatter(); f.format("%s", getWebappVersion()); if (getTdsVersionBuildDate() != null) { f.format(" - %s", getTdsVersionBuildDate()); } return f.toString(); }  @Override void setServletContext(ServletContext servletContext); ServletContext getServletContext(); @Override void destroy(); @Override void afterPropertiesSet(); @Override String toString(); String getContextPath(); String getWebappVersion(); String getTdsVersionBuildDate(); String getVersionInfo(); String getWebappDisplayName(); File getServletRootDirectory(); File getTomcatLogDirectory(); File getThreddsDirectory(); File getContentRootDir(); FileSource getPublicContentDirSource(); RequestDispatcher getDefaultRequestDispatcher(); String getContentRootPathProperty(); String getConfigFileProperty(); File getUploadDir(); File getDownloadDir(); File getUploadForm(); File getDownloadForm(); String getTdsDebugFlags(); void setContentRootPathProperty(String contentRootPathProperty); void setUploadDirProperty(String uploadDirProperty); void setDownloadDirProperty(String downloadDirProperty); void setUploadFormProperty(String uploadFormProperty); void setDownloadFormProperty(String downloadFormProperty); File getPropertyDir(String prop, String key, boolean create); File getPropertyFile(String prop, String key, boolean writeable);  }