(command.CommandList children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'test_description='> name:test_description) op: assign_op.Equal rhs: {(DQ <'Gettext reencoding of our *.po/*.mo files works'>)} spids: [13] ) ] redirects: [] ) (C {<.>} {<'./lib-gettext.sh'>}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'RUNES='> name:RUNES) op: assign_op.Equal rhs: { (DQ < 'TILRAUN: ᚻᛖ ᚳᚹᚫᚦ ᚦᚫᛏ ᚻᛖ ᛒᚢᛞᛖ ᚩᚾ ᚦᚫᛗ ᛚᚪᚾᛞᛖ ᚾᚩᚱᚦᚹᛖᚪᚱᛞᚢᛗ ᚹᛁᚦ ᚦᚪ ᚹᛖᛥᚫ' > ) } spids: [27] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'PUNTS='> name:PUNTS) op: assign_op.Equal rhs: {(DQ <'TILRAUN: ?? ???? ??? ?? ???? ?? ??? ????? ??????????? ??? ?? ????'>)} spids: [32] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'MSGKEY='> name:MSGKEY) op: assign_op.Equal rhs: {(DQ <'TEST: Old English Runes'>)} spids: [37] ) ] redirects: [] ) (C {<test_expect_success>} {<GETTEXT_LOCALE>} {(SQ <'gettext: Emitting UTF-8 from our UTF-8 *.mo files / Icelandic'>)} { (SQ <'\n'> <' printf "TILRAUN: Halló Heimur!" >expect &&\n'> <' LANGUAGE=is LC_ALL="$is_IS_locale" gettext "TEST: Hello World!" >actual &&\n'> <' test_cmp expect actual\n'> ) } ) (C {<test_expect_success>} {<GETTEXT_LOCALE>} {(SQ <'gettext: Emitting UTF-8 from our UTF-8 *.mo files / Runes'>)} { (SQ <'\n'> <' printf "%s" "$RUNES" >expect &&\n'> <' LANGUAGE=is LC_ALL="$is_IS_locale" gettext "$MSGKEY" >actual &&\n'> <' test_cmp expect actual\n'> ) } ) (C {<test_expect_success>} {<GETTEXT_ISO_LOCALE>} {(SQ <'gettext: Emitting ISO-8859-1 from our UTF-8 *.mo files / Icelandic'>)} { (SQ <'\n'> <' printf "TILRAUN: Halló Heimur!" | iconv -f UTF-8 -t ISO8859-1 >expect &&\n'> <' LANGUAGE=is LC_ALL="$is_IS_iso_locale" gettext "TEST: Hello World!" >actual &&\n'> <' test_cmp expect actual\n'> ) } ) (C {<test_expect_success>} {<GETTEXT_ISO_LOCALE>} {(SQ <'gettext: impossible ISO-8859-1 output'>)} { (SQ <'\n'> <'\tLANGUAGE=is LC_ALL="$is_IS_iso_locale" gettext "$MSGKEY" >runes &&\n'> <'\tcase "$(cat runes)" in\n'> <'\t"$MSGKEY")\n'> <'\t\tsay "Your system gives back the key to message catalog"\n'> <'\t\t;;\n'> <'\t"$PUNTS")\n'> <'\t\tsay "Your system replaces an impossible character with ?"\n'> <'\t\t;;\n'> <'\t"$RUNES")\n'> <'\t\tsay "Your system gives back the raw message for an impossible request"\n'> <'\t\t;;\n'> <'\t*)\n'> <'\t\tsay "We never saw the error behaviour your system exhibits"\n'> <'\t\tfalse\n'> <'\t\t;;\n'> <'\tesac\n'> ) } ) (C {<test_expect_success>} {<GETTEXT_LOCALE>} {(SQ <'gettext: Fetching a UTF-8 msgid -> UTF-8'>)} { (SQ <'\n'> <' printf "TILRAUN: ‚einfaldar‘ og „tvöfaldar“ gæsalappir" >expect &&\n'> < ' LANGUAGE=is LC_ALL="$is_IS_locale" gettext "TEST: ‘single’ and “double” quotes" >actual &&\n' > <' test_cmp expect actual\n'> ) } ) (C {<test_expect_success>} {<GETTEXT_ISO_LOCALE>} {(SQ <'gettext: Fetching a UTF-8 msgid -> ISO-8859-1'>)} { (SQ <'\n'> < ' LANGUAGE=is LC_ALL="$is_IS_iso_locale" gettext "TEST: ‘single’ and “double” quotes" >actual &&\n' > <' grep "einfaldar" actual &&\n'> <' grep "$(echo tvöfaldar | iconv -f UTF-8 -t ISO8859-1)" actual\n'> ) } ) (C {<test_expect_success>} {<GETTEXT_LOCALE>} {(SQ <'gettext.c: git init UTF-8 -> UTF-8'>)} { (SQ <'\n'> <' printf "Bjó til tóma Git lind" >expect &&\n'> <' LANGUAGE=is LC_ALL="$is_IS_locale" git init repo >actual &&\n'> <' test_when_finished "rm -rf repo" &&\n'> <' grep "^$(cat expect) " actual\n'> ) } ) (C {<test_expect_success>} {<GETTEXT_ISO_LOCALE>} {(SQ <'gettext.c: git init UTF-8 -> ISO-8859-1'>)} { (SQ <'\n'> <' printf "Bjó til tóma Git lind" >expect &&\n'> <' LANGUAGE=is LC_ALL="$is_IS_iso_locale" git init repo >actual &&\n'> <' test_when_finished "rm -rf repo" &&\n'> <' grep "^$(cat expect | iconv -f UTF-8 -t ISO8859-1) " actual\n'> ) } ) (C {<test_done>}) ] )