Fix persistence tests treating class terms differently