Watch out for repeat warning filters. I've mocked warnings.warn in the past, but any simple solution is fine.