encoding-guesser: Don't guess UTF-8 for ASCII if it is the fallback.
authorBen Pfaff <blp@cs.stanford.edu>
Wed, 27 Apr 2011 04:36:24 +0000 (21:36 -0700)
committerBen Pfaff <blp@cs.stanford.edu>
Wed, 27 Apr 2011 04:36:24 +0000 (21:36 -0700)
When the text presented to the encoding guesser is all ASCII, normally
the encoding guesser will report ASCII as its guess.  But if the
fallback encoding is UTF-8, then it reports UTF-8 instead.
Unfortunately, this makes the encoding guesser a bit harder to test,
because guesses depend on the system's locale.  It's easier to test
if all-ASCII always yields ASCII as the guess, so this changes the
encoding guesser to do that.

This fixes a test failure on Mac OS X.  Thanks to Jeremy Lavergne for
reporting the problem.


No differences found