Add unit test for cleared cache, and adjust existing unit test which
assumed cached position