def test_unicode(self):
    with mktemp('Проверка {{ a }} связи!') as template:
        with mktemp('{"a": "широкополосной"}') as context:
            self._testme(['--format=json', template, context], 'Проверка широкополосной связи!')
    if (sys.version_info[0] == 2):
        self._testme(['resources/name.j2'], u'Hello Jürgen!\n', env=dict(name=b'J\xc3\xbcrgen'))
    else:
        self._testme(['resources/name.j2'], u'Hello Jürgen!\n', env=dict(name=u'Jürgen'))
def test_unicode(self):
    with mktemp('Проверка {{ a }} связи!') as template:
        with mktemp('{"a": "широкополосной"}') as context:
            self._testme(['--format=json', template, context], 'Проверка широкополосной связи!')
    if (sys.version_info[0] == 2):
        self._testme(['resources/name.j2'], u'Hello Jürgen!\n', env=dict(name=b'J\xc3\xbcrgen'))
    else:
        self._testme(['resources/name.j2'], u'Hello Jürgen!\n', env=dict(name=u'Jürgen'))