Adapt functest testcase to APi refactoring