private String getValueFor(String property) {
   if (property == null) return null;
   String result = TestActivator.getContext().getProperty(property);
   if (result == null && archiveAndRepositoryProperties == null) return null;
   if (result == null) archiveAndRepositoryProperties.getProperty(property);
   if (result == null)
     result = archiveAndRepositoryProperties.getProperty(property + '.' + Platform.getOS());
   return result;
 }
 private static void loadPlatformZipPropertiesFromFile() {
   File installLocation = getInstallLocation();
   if (installLocation != null) {
     // parent will be "eclipse" and the parent's parent will be "eclipse-testing"
     File parent = installLocation.getParentFile();
     if (parent != null) {
       parent = parent.getParentFile();
       if (parent != null) {
         File propertiesFile = new File(parent, "equinoxp2tests.properties");
         if (!propertiesFile.exists()) return;
         archiveAndRepositoryProperties = new Properties();
         try {
           InputStream is = null;
           try {
             is = new BufferedInputStream(new FileInputStream(propertiesFile));
             archiveAndRepositoryProperties.load(is);
           } finally {
             is.close();
           }
         } catch (IOException e) {
           return;
         }
       }
     }
   }
 }
 /*
  * Create a link file in the links folder. Point it to the given extension location.
  */
 public void createLinkFile(String message, String filename, String extensionLocation) {
   File file = new File(output, getRootFolder() + "links/" + filename + ".link");
   file.getParentFile().mkdirs();
   Properties properties = new Properties();
   properties.put("path", extensionLocation);
   OutputStream stream = null;
   try {
     stream = new BufferedOutputStream(new FileOutputStream(file));
     properties.store(stream, null);
   } catch (IOException e) {
     fail(message, e);
   } finally {
     try {
       if (stream != null) stream.close();
     } catch (IOException e) {
       // ignore
     }
   }
 }