Add new tests for conversion (that now fail...)
[fanfix.git] / src / be / nikiroo / fanfix / test / Test.java
index 3ff9a7ab8d139ad3e42c46f9caed8d504021f5e7..dd412ec4ba6ae75cdd0bae436e166bcde3100b4a 100644 (file)
@@ -29,6 +29,7 @@ public class Test extends TestLauncher {
                Instance.setTraceHandler(null);
                addSeries(new BasicSupportTest(args));
                addSeries(new LibraryTest(args));
+               addSeries(new ConversionTest(args));
        }
 
        /**
@@ -47,12 +48,17 @@ public class Test extends TestLauncher {
                tmpCache.delete();
                tmpCache.mkdir();
 
-               FileOutputStream out = new FileOutputStream(new File(tmpConfig,
-                               "config.properties"));
-               Properties props = new Properties();
-               props.setProperty("CACHE_DIR", tmpCache.getAbsolutePath());
-               props.store(out, null);
-               out.close();
+               FileOutputStream out = null;
+               try {
+                       out = new FileOutputStream(new File(tmpConfig, "config.properties"));
+                       Properties props = new Properties();
+                       props.setProperty("CACHE_DIR", tmpCache.getAbsolutePath());
+                       props.store(out, null);
+               } finally {
+                       if (out != null) {
+                               out.close();
+                       }
+               }
 
                ConfigBundle config = new ConfigBundle();
                Bundles.setDirectory(tmpConfig.getAbsolutePath());