started tests
fixed some stuff
get sec from mongo date object