Fixed the build error int test_api_v2.py