private void set_Backend_ArchivePath_AndHadoopProperties(String hadoopHost, String hadoopPort)
     throws IOException {
   File hdfsPropertiesFile =
       BackendConfigurationFiles.create().getByName(HdfsProperties.HDFS_PROPERTIES_FILENAME);
   try {
     runHdfsTestCase(hdfsPropertiesFile);
   } finally {
     teardown(hadoopHost, hadoopPort, hdfsPropertiesFile);
   }
 }
  private void set_Backend_archivePath_andAmazonProperties() throws IOException {
    String id = "theId";
    String secret = "theSecret";
    String bucket = "theBucket";
    String archiverRootURI = "s3n://" + id + ":" + secret + "@" + bucket + "/archiver_root";

    createArchiverMbeanWithArchiverRootURI(archiverRootURI);
    assertEquals("s3n", archiverMBean.getBackendName());
    assertEquals("/archiver_root", archiverMBean.getArchivePath());

    Properties amazonProperties = new Properties();
    File amazonPropertiesFile =
        BackendConfigurationFiles.create().getByName(AWSCredentialsImpl.AMAZON_PROPERTIES_FILENAME);
    amazonProperties.load(FileUtils.openInputStream(amazonPropertiesFile));
    assertEquals(id, amazonProperties.getProperty("aws.id"));
    assertEquals(secret, amazonProperties.getProperty("aws.secret"));
    assertEquals(bucket, amazonProperties.getProperty("s3.bucket"));
  }