blob: bb46ca0db37bf0a3c6ab1bfcde002094d62af35e [file] [log] [blame]
Christ van Willegence0ef912024-06-20 23:41:59 +02001source check.vim
Christian Brabandt6bc11c02024-06-21 07:31:04 +02002" TODO: Why does this fail on MacOS 14 and Windows MSVC (Github CI)?
3CheckNotMac
4CheckNotMSWindows
Christ van Willegence0ef912024-06-20 23:41:59 +02005
6" Test for gettext()
7func Test_gettext()
8 set encoding=utf-8
9 call bindtextdomain("__PACKAGE__", getcwd())
10 try
11 language ru_RU
12 call assert_equal('ОШИБКА: ', gettext("ERROR: ", "__PACKAGE__"))
13 catch /^Vim\%((\a\+)\)\=:E197:/
14 throw "Skipped: not possible to set locale to ru (missing?)"
15 endtry
16 try
17 language en_GB.UTF-8
18 call assert_equal('ERROR: ', gettext("ERROR: ", "__PACKAGE__"))
19 catch /^Vim\%((\a\+)\)\=:E197:/
20 throw "Skipped: not possible to set locale to en (missing?)"
21 endtry
22 set encoding&
23endfunc
24
25" vim: shiftwidth=2 sts=2 expandtab