@Test
  public void testOpenErrorMessageReference() throws IOException {
    // Test file link exception
    // Try to open nonsense hfilelink. Make sure exception is from HFileLink.
    Path p = new Path(TEST_UTIL.getDataTestDirOnTestFS(), "4567.abcd");
    FileSystem fs = FileSystem.get(TEST_UTIL.getConfiguration());
    fs.mkdirs(p.getParent());
    Reference r = Reference.createBottomReference(HConstants.EMPTY_START_ROW);
    RegionInfo regionInfo = RegionInfoBuilder.newBuilder(TableName.valueOf("table1")).build();
    StoreContext storeContext = StoreContext.getBuilder()
      .withRegionFileSystem(HRegionFileSystem.create(TEST_UTIL.getConfiguration(), fs,
        TEST_UTIL.getDataTestDirOnTestFS(), regionInfo))
      .withColumnFamilyDescriptor(
        ColumnFamilyDescriptorBuilder.newBuilder("cf1".getBytes()).build())
      .build();
    StoreFileTrackerForTest storeFileTrackerForTest =
      new StoreFileTrackerForTest(TEST_UTIL.getConfiguration(), true, storeContext);
    storeFileTrackerForTest.createReference(r, p);
    StoreFileInfo sfi = storeFileTrackerForTest.getStoreFileInfo(p, true);
    try {
      ReaderContext context = sfi.createReaderContext(false, 1000, ReaderType.PREAD);
      sfi.createReader(context, null);
      throw new IllegalStateException();
    } catch (FileNotFoundException fnfe) {
      assertTrue(fnfe.getMessage().contains("->"));
    }
  }
Validate that we can handle valid tables with '.', '_', and '-' chars.
hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestStoreFileInfo.java