bowenli86 commented on a change in pull request #8212: [FLINK-11519][table] Add 
function related catalog APIs
URL: https://github.com/apache/flink/pull/8212#discussion_r277954981
 
 

 ##########
 File path: 
flink-table/flink-table-api-java/src/test/java/org/apache/flink/table/catalog/GenericInMemoryCatalogTest.java
 ##########
 @@ -562,6 +568,158 @@ public void testRenameView() throws Exception {
                catalog.dropTable(viewPath2, false);
        }
 
+       // ------ functions ------
+
+       @Test
+       public void testCreateFunction() throws Exception {
+               catalog.createDatabase(db1, createDb(), false);
+
+               assertFalse(catalog.functionExists(path1));
+
+               catalog.createFunction(path1, createFunction(), false);
+
+               assertTrue(catalog.functionExists(path1));
+
+               catalog.dropFunction(path1, false);
 
 Review comment:
   close() will be called after each unit test finishes to remove side-effects 
between tests. Leaving dropFunction() within unit tests, for example here, may 
mislead people that we are intentionally testing it, though it's only used for 
cleanup purpose.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to