Fix tests broken by fa40839097a97349f2831ba4a8d6f611c1e8e27d,
the error messages have changed, re-write the tests to expect
more general patterns rather than specific error strings.