added unittest for fastfunc