SystemUtil { public static String getEnv(String key) { Map map = System.getenv(); Iterator it = map.entrySet().iterator(); while (it.hasNext()) { Entry entry = (Entry) it.next(); if (entry.getKey().equals(key)) { return entry.getValue().toString(); } } return null; }  static String getEnv(String key);  }
@Test public void getEnv() { String home = SystemUtil.getEnv("GRADLE_HOME"); Assert.assertNotNull(home); }