Merge "Add unit tests for api_version detection"