fix unit tests (#4872)