Added Unit Tests and changed peak functions to better suit Surbhi.