~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/blackbox/test_command_encoding.py

  • Committer: Patch Queue Manager
  • Date: 2016-04-21 04:10:52 UTC
  • mfrom: (6616.1.1 fix-en-user-guide)
  • Revision ID: pqm@pqm.ubuntu.com-20160421041052-clcye7ns1qcl2n7w
(richard-wilbur) Ensure build of English use guide always uses English text
 even when user's locale specifies a different language. (Jelmer Vernooij)

Show diffs side-by-side

added added

removed removed

Lines of Context:
54
54
        register_command(cmd_echo_exact)
55
55
        try:
56
56
            self.assertEqual('foo', bzr('echo-exact foo'))
57
 
            # This is cheating a little bit, because 'foo\xb5' shouldn't
58
 
            # get past main()
59
 
            self.assertEqual('foo\xb5', bzr('echo-exact foo\xb5'))
60
57
            # Exact should fail to decode the string
61
58
            self.assertRaises(UnicodeEncodeError,
62
59
                bzr,
63
60
                ['echo-exact', u'foo\xb5'])
 
61
            # Previously a non-ascii bytestring was also tested, as 'exact'
 
62
            # outputs bytes untouched, but needed buggy argv parsing to work
64
63
        finally:
65
64
            plugin_cmds.remove('echo-exact')
66
65