### Question:
HbaseMetadataHandler extends GlueMetadataHandler { @Override public ListTablesResponse doListTables(BlockAllocator blockAllocator, ListTablesRequest request) throws IOException { List<com.amazonaws.athena.connector.lambda.domain.TableName> tableNames = new ArrayList<>(); TableName[] tables = getOrCreateConn(request).listTableNamesByNamespace(request.getSchemaName()); for (int i = 0; i < tables.length; i++) { TableName tableName = tables[i]; tableNames.add(new com.amazonaws.athena.connector.lambda.domain.TableName(request.getSchemaName(), tableName.getNameAsString().replace(request.getSchemaName() + ":", ""))); } return new ListTablesResponse(request.getCatalogName(), tableNames); } HbaseMetadataHandler(); @VisibleForTesting protected  HbaseMetadataHandler(AWSGlue awsGlue,
            EncryptionKeyFactory keyFactory,
            AWSSecretsManager secretsManager,
            AmazonAthena athena,
            HbaseConnectionFactory connectionFactory,
            String spillBucket,
            String spillPrefix); @Override ListSchemasResponse doListSchemaNames(BlockAllocator blockAllocator, ListSchemasRequest request); @Override ListTablesResponse doListTables(BlockAllocator blockAllocator, ListTablesRequest request); @Override GetTableResponse doGetTable(BlockAllocator blockAllocator, GetTableRequest request); @Override void getPartitions(BlockWriter blockWriter, GetTableLayoutRequest request, QueryStatusChecker queryStatusChecker); @Override GetSplitsResponse doGetSplits(BlockAllocator blockAllocator, GetSplitsRequest request);  }### Answer:
@Test public void doListTables() throws IOException { logger.info("doListTables - enter"); String schema = "schema1"; org.apache.hadoop.hbase.TableName[] tables = { org.apache.hadoop.hbase.TableName.valueOf("schema1", "table1"), org.apache.hadoop.hbase.TableName.valueOf("schema1", "table2"), org.apache.hadoop.hbase.TableName.valueOf("schema1", "table3") }; Set<String> tableNames = new HashSet<>(); tableNames.add("table1"); tableNames.add("table2"); tableNames.add("table3"); when(mockClient.listTableNamesByNamespace(eq(schema))).thenReturn(tables); ListTablesRequest req = new ListTablesRequest(IDENTITY, QUERY_ID, DEFAULT_CATALOG, schema); ListTablesResponse res = handler.doListTables(allocator, req); logger.info("doListTables - {}", res.getTables()); for (TableName next : res.getTables()) { assertEquals(schema, next.getSchemaName()); assertTrue(tableNames.contains(next.getTableName())); } assertEquals(tableNames.size(), res.getTables().size()); }