MAINT/API: Fix broken tests due to dperecated API