piranha/opster — pull request #42 by oscarbenjamin (2012-05-30 09:05:41+00:00)
Title: Use default encoding (including in cram tests) fix for GH-41

This pull request changes so that opster uses the default system encodings for arguments and output unless instructed otherwise by the env vars `OPSTER_ARG_ENCODING` or `OPSTER_OUT_ENCODING`. These env vars are then used in the test suite where appropriate to ensure that the tests use the expected encoding.

It turns out that the reason my systems were unable to encode the output from some of the opster tests was in fact because `cram` was setting `LANG=C`. This has been changed by using the `--preserve-env` option to `cram`. I can then get all the tests to pass on linux and windows without special casing any encodings and replacing them with `'utf-8'`.