Check for encodings in get_file tests and fix some bad implementations.
Review Request #9790 — Created March 15, 2018 and submitted
We had a couple hosting services (Beanstalk and Kiln) that were
returning Unicode strings instead of byte strings in their
implementations. This fixes those and adds checks to all test suites
Unit tests pass.