### Question:
FullReplicationReplicaLocationManager implements ReplicaLocationManager { @Override public Path getPartitionBaseLocation() { if (tableType == UNPARTITIONED) { throw new UnsupportedOperationException("Not a partitioned table."); } Path partitionBasePath = new Path(getTableLocation(), eventId); LOG.debug("Generated partition data destination base path: {}", partitionBasePath.toUri()); return partitionBasePath; } FullReplicationReplicaLocationManager(
      SourceLocationManager sourceLocationManager,
      String tablePath,
      String eventId,
      TableType tableType,
      CleanupLocationManager cleanupLocationManager,
      ReplicaCatalogListener replicaCatalogListener); @Override Path getTableLocation(); @Override Path getPartitionBaseLocation(); @Override void addCleanUpLocation(String pathEventId, Path location); @Override void cleanUpLocations(); @Override Path getPartitionLocation(Partition sourcePartition);  }### Answer:
@Test(expected = UnsupportedOperationException.class) public void getPartitionBaseOnUnpartitionedTable() throws Exception { FullReplicationReplicaLocationManager manager = new FullReplicationReplicaLocationManager(sourceLocationManager, TABLE_PATH, EVENT_ID, UNPARTITIONED, cleanupLocationManager, replicaCatalogListener); manager.getPartitionBaseLocation(); }
@Test public void getPartitionBaseOnPartitionedTable() throws Exception { FullReplicationReplicaLocationManager manager = new FullReplicationReplicaLocationManager(sourceLocationManager, TABLE_PATH, EVENT_ID, PARTITIONED, cleanupLocationManager, replicaCatalogListener); Path path = manager.getPartitionBaseLocation(); assertThat(path, is(new Path(TABLE_PATH, new Path(EVENT_ID)))); }