Fixed some doctest syntax errors.
Fixed failed unit test.

Fixed
-----
* This fixes the unit test that sometimes failed saying that 5 isn't of type
  int.
Changed BAD_INDEX_VALUE to by max int32.

Changed
-------
* BAD_INDEX_VALUE is now max representable by a 32-bit integer.