### Question:
MultiRFileOutputFormatter extends FileOutputFormat<BulkIngestKey,Value> { public static void setAccumuloConfiguration(Configuration conf) { conf.set(INSTANCE_NAME, conf.get(AccumuloHelper.INSTANCE_NAME)); conf.set(USERNAME, conf.get(AccumuloHelper.USERNAME)); conf.set(PASSWORD, conf.get(AccumuloHelper.PASSWORD)); conf.set(ZOOKEEPERS, conf.get(AccumuloHelper.ZOOKEEPERS)); }  static void setGenerateMapFileRowKeys(Configuration conf, boolean generateMapFileRowKeys); static void setGenerateMapFilePerShardLocation(Configuration conf, boolean generateMapFilePerShardLocation); static void setCompressionType(Configuration conf, String compressionType); static void setCompressionTableBlackList(Configuration conf, Set<String> compressionTableBlackList); static void setFileType(Configuration conf, String type); static void setAccumuloConfiguration(Configuration conf); static void setRFileLimits(Configuration conf, int maxEntries, long maxSize); static void addTableToLocalityGroupConfiguration(Configuration conf, String tableName); @Override synchronized OutputCommitter getOutputCommitter(TaskAttemptContext context); @Override RecordWriter<BulkIngestKey,Value> getRecordWriter(final TaskAttemptContext context); static final String CONFIGURE_LOCALITY_GROUPS; static final String EVENT_PARTITION_COUNT; static final String EDGE_PARTITION_COUNT; static final String INDEX_PARTITION_COUNT; static final String REV_INDEX_PARTITION_COUNT; static final String LOCATION_PARTITION_COUNT; static final String CONFIGURED_TABLE_NAMES; }### Answer:
@Test public void testSetAccumuloConfiguration() { MultiRFileOutputFormatterTest.logger.info("testSetFileType called..."); try { String instance = "instance"; String username = "user"; byte[] password = "passw0rd".getBytes(); String zookeepers = "zookeepers"; Configuration conf = new Configuration(); AccumuloHelper.setInstanceName(conf, instance); AccumuloHelper.setUsername(conf, username); AccumuloHelper.setPassword(conf, password); AccumuloHelper.setZooKeepers(conf, zookeepers); MultiRFileOutputFormatter.setAccumuloConfiguration(conf); createMockConfiguration(); String instanceKey = String.format("%s.instance.name", MultiRFileOutputFormatter.class.getName()); String usernameKey = String.format("%s.username", MultiRFileOutputFormatter.class.getName()); String passwordKey = String.format("%s.password", MultiRFileOutputFormatter.class.getName()); String zooKeeperKey = String.format("%s.zookeepers", MultiRFileOutputFormatter.class.getName()); Assert.assertEquals("MultiRFileOutputFormatter#setAccumuloConfiguration failed to retain the expected instance value.", instance, conf.get(instanceKey)); Assert.assertEquals("MultiRFileOutputFormatter#setAccumuloConfiguration failed to retain the expected username value.", username, conf.get(usernameKey)); Assert.assertEquals("MultiRFileOutputFormatter#setAccumuloConfiguration failed to retain the expected password value.", new String(Base64.encodeBase64(password)), conf.get(passwordKey)); Assert.assertEquals("MultiRFileOutputFormatter#setAccumuloConfiguration failed to retain the expected zookeepers value.", zookeepers, conf.get(zooKeeperKey)); } finally { MultiRFileOutputFormatterTest.logger.info("testSetFileType completed."); } }