Refactored cursor tests