added test and fixed functor multi