Refactor bin file and Timeline class, add spec for new timeline class