### Question:
HbaseMetadataHandler extends GlueMetadataHandler { @Override public ListSchemasResponse doListSchemaNames(BlockAllocator blockAllocator, ListSchemasRequest request) throws IOException { List<String> schemas = new ArrayList<>(); NamespaceDescriptor[] namespaces = getOrCreateConn(request).listNamespaceDescriptors(); for (int i = 0; i < namespaces.length; i++) { NamespaceDescriptor namespace = namespaces[i]; schemas.add(namespace.getName()); } return new ListSchemasResponse(request.getCatalogName(), schemas); } 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 doListSchemaNames() throws IOException { NamespaceDescriptor[] schemaNames = {NamespaceDescriptor.create("schema1").build(), NamespaceDescriptor.create("schema2").build(), NamespaceDescriptor.create("schema3").build()}; when(mockClient.listNamespaceDescriptors()).thenReturn(schemaNames); ListSchemasRequest req = new ListSchemasRequest(IDENTITY, QUERY_ID, DEFAULT_CATALOG); ListSchemasResponse res = handler.doListSchemaNames(allocator, req); logger.info("doListSchemas - {}", res.getSchemas()); Set<String> expectedSchemaName = new HashSet<>(); expectedSchemaName.add("schema1"); expectedSchemaName.add("schema2"); expectedSchemaName.add("schema3"); assertEquals(expectedSchemaName, new HashSet<>(res.getSchemas())); logger.info("doListSchemaNames: exit"); }