add some test and functionals