add test functions for array