fix test error due to changed api