moved utils out of core. fixed tests