Remove old helper method in api tests