@Test
 public void testFeatureReaderFidFilter() throws Exception {
   FeatureReader<SimpleFeatureType, SimpleFeature> fr;
   fr = rts.getFeatureReader(new Query(RENAMED, fidFilter), Transaction.AUTO_COMMIT);
   assertEquals(primitive, fr.getFeatureType());
   assertTrue(fr.hasNext());
   SimpleFeature sf = fr.next();
   assertFalse(fr.hasNext());
   fr.close();
   assertEquals(fid, sf.getID());
 }
  @Test
  public void testGetFeaturesReader() throws Exception {
    FeatureReader<SimpleFeatureType, SimpleFeature> fr;
    fr = rts.getFeatureReader(new Query(RENAMED), Transaction.AUTO_COMMIT);
    SimpleFeature sf = fr.next();
    fr.close();

    assertEquals(primitive, sf.getFeatureType());

    // check the feature ids have been renamed as well
    assertTrue(
        "Feature id has not been renamed, it's still " + sf.getID(),
        sf.getID().startsWith(RENAMED));
  }