### Question:
MetadataUpdateReplicaLocationManager implements ReplicaLocationManager { @Override public Path getPartitionLocation(Partition sourcePartition) { if (tableType == UNPARTITIONED) { throw new UnsupportedOperationException("Not a partitioned table."); } try { Partition partition = replicaMetastoreClient.getPartition(replicaDatabaseName, replicaTableName, sourcePartition.getValues()); return new Path(partition.getSd().getLocation()); } catch (TException e) { throw new CircusTrainException("Partition should exist on replica but doesn't", e); } } MetadataUpdateReplicaLocationManager(
      CloseableMetaStoreClient replicaMetastoreClient,
      TableType tableType,
      String tablePath,
      String replicaDatabaseName,
      String replicaTableName); @Override Path getTableLocation(); @Override Path getPartitionBaseLocation(); @Override void cleanUpLocations(); @Override void addCleanUpLocation(String pathEventId, Path location); @Override Path getPartitionLocation(Partition sourcePartition);  }### Answer:
@Test(expected = UnsupportedOperationException.class) public void unpartitionedTableLocationThrowsExceptionOnPartitionLocation() throws Exception { MetadataUpdateReplicaLocationManager replicaLocationManager = new MetadataUpdateReplicaLocationManager(client, TableType.UNPARTITIONED, tableLocation, DATABASE, TABLE); replicaLocationManager.getPartitionLocation(sourcePartition); }