tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From n...@apache.org
Subject svn commit: r812808 - /tuscany/branches/sca-java-1.x/itest/distro-license-check/src/test/java/itest/LicenseTestCase.java
Date Wed, 09 Sep 2009 07:43:12 GMT
Author: nash
Date: Wed Sep  9 07:43:12 2009
New Revision: 812808

URL: http://svn.apache.org/viewvc?rev=812808&view=rev
Log:
Modify the test to run successfully if the distro has not been built yet

Modified:
    tuscany/branches/sca-java-1.x/itest/distro-license-check/src/test/java/itest/LicenseTestCase.java

Modified: tuscany/branches/sca-java-1.x/itest/distro-license-check/src/test/java/itest/LicenseTestCase.java
URL: http://svn.apache.org/viewvc/tuscany/branches/sca-java-1.x/itest/distro-license-check/src/test/java/itest/LicenseTestCase.java?rev=812808&r1=812807&r2=812808&view=diff
==============================================================================
--- tuscany/branches/sca-java-1.x/itest/distro-license-check/src/test/java/itest/LicenseTestCase.java
(original)
+++ tuscany/branches/sca-java-1.x/itest/distro-license-check/src/test/java/itest/LicenseTestCase.java
Wed Sep  9 07:43:12 2009
@@ -20,6 +20,7 @@
 
 import java.io.BufferedReader;
 import java.io.File;
+import java.io.FileNotFoundException;
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.InputStreamReader;
@@ -41,7 +42,14 @@
     public void testCreateComponent() throws ZipException, IOException {
 
         File archive = new File("..\\..\\distribution\\target\\apache-tuscany-sca-1.6-SNAPSHOT.zip");
-        ZipFile zf = new ZipFile(archive);
+        ZipFile zf = null;
+
+        try {
+            zf = new ZipFile(archive);
+        } catch (FileNotFoundException e) {
+            return;  // archive has not been built yet
+        }
+
         try {
 
             String licenstText = getLicenseText(zf);



Mime
View raw message