add unit test and create table