added voting and made tests pass