@Test
  public void testParameterExpansion() throws TException {
    GetPartitionsRequest request = getGetPartitionsRequest();
    GetProjectionsSpec projectSpec = request.getProjectionSpec();
    projectSpec.setFieldList(Arrays.asList("sd.cols", "sd.serdeInfo"));

    GetPartitionsResponse response = client.getPartitionsWithSpecs(request);

    PartitionSpecWithSharedSD partitionSpecWithSharedSD =
        response.getPartitionSpec().get(0).getSharedSDPartitionSpec();
    StorageDescriptor sharedSD = partitionSpecWithSharedSD.getSd();
    Assert.assertNotNull("sd.cols were requested but was not returned", sharedSD.getCols());
    Assert.assertEquals("Returned serdeInfo does not match with original serdeInfo",
        origPartitions.get(0).getSd().getCols(), sharedSD.getCols());

    Assert
        .assertNotNull("sd.serdeInfo were requested but was not returned", sharedSD.getSerdeInfo());
    Assert.assertEquals("Returned serdeInfo does not match with original serdeInfo",
        origPartitions.get(0).getSd().getSerdeInfo(), sharedSD.getSerdeInfo());
  }
Confirms if the partitionWithoutSD object at partitionWithoutSDSIndex index has all the
projected fields set to values which are same as the ones set in origPartitions
@param projectedFields
@param sharedSD
@param partitionWithoutSDS
@param partitionWithoutSDSIndex
@throws IllegalAccessException
@throws InvocationTargetException
@throws NoSuchMethodException
standalone-metastore/metastore-server/src/test/java/org/apache/hadoop/hive/metastore/TestGetPartitionsUsingProjectionAndFilterSpecs.java