Clover Coverage Report - Liquibase Core 2.0.3-SNAPSHOT
Coverage timestamp: Sat Aug 6 2011 11:33:15 EDT
../../img/srcFileCovDistChart8.png 14% of files have more coverage
13   32   4   13
4   28   0.31   1
1     4  
1    
 
  LiquibaseUtil       Line # 8 13 0% 4 5 72.2% 0.7222222
 
  (1)
 
1    package liquibase.util;
2   
3    import java.io.IOException;
4    import java.io.InputStream;
5    import java.net.URL;
6    import java.util.Properties;
7   
 
8    public class LiquibaseUtil {
 
9  1 toggle public static String getBuildVersion() {
10  1 Properties buildInfo = new Properties();
11  1 ClassLoader classLoader = LiquibaseUtil.class.getClassLoader();
12   
13  1 URL buildInfoFile = classLoader.getResource("buildinfo.properties");
14  1 try {
15  1 if (buildInfoFile == null) {
16  0 return "UNKNOWN";
17    } else {
18  1 InputStream in = buildInfoFile.openStream();
19   
20  1 buildInfo.load(in);
21  1 String o = (String) buildInfo.get("build.version");
22  1 if (o == null) {
23  0 return "UNKNOWN";
24    } else {
25  1 return o;
26    }
27    }
28    } catch (IOException e) {
29  0 return "UNKNOWN";
30    }
31    }
32    }