changed api of managers and added metric manager test