TST : fix font-priority test

For reasons I don't understand wrapping the test in a cleanup decorator
seems to make it pass consistently.

Closes #3065