ENH: More explicit warning matching in tests