test: use I18N::Langinfo to test for 7/8-bit locale

- Use I18N::Langinfo to see if the test is running in a 7-bit or 8-bit
  locale; skip wide-byte tests if running in 7-bit, or if
  I18N::Langinfo can't be loaded for whatever reason