Improve unit tests to test off by one