Fix bug cleaning up removed Functions and fix test_ddl to create all test dbs

When dropping functions, we neeed to remove the function from the list
of Functions with that name AND remove the list from the Function map if
the list is empty. The second part wasn't happening.

Also fixes the test_ddl to properly create all test databases.

Change-Id: Id85af7d5db74a31161f48bea3816bdf734063133
Reviewed-on: http://gerrit.ent.cloudera.com:8080/952
Reviewed-by: Nong Li <nong@cloudera.com>
Tested-by: jenkins
This commit is contained in:
Lenni Kuff
2013-11-18 09:16:11 -08:00
committed by Henry Robinson
parent 04ebe68212
commit 6bba0c8ffe
4 changed files with 34 additions and 47 deletions

View File

@@ -1,8 +1,5 @@
====
---- QUERY
create database if not exists function_ddl_test
====
---- QUERY
# Drop the dummy udfs this test uses.
drop function if exists default.fn();
drop function if exists function_ddl_test.fn();