How to set locale (French) valid for Windows and Unix?
My full robot test is:
*** Settings ***
Library SeleniumLibrary
Library DateTime
*** Keywords ***
Get Next Week French date
Evaluate locale.setlocale(locale.LC_ALL, 'fr_FR.UTF-8') locale
${today}= Get Time
${tomorrow}= Add Time To Date ${today} 1 days
${three_day_after}= Add Time To Date ${today} 3 days
${today_day}= Convert Date ${today} result_format=%a
Log To Console ${today_day}
${next_date}= Set Variable If "${today_day}"=="ven." ${three_day_after} ${tomorrow}
${next_week}= Add Time To Date ${next_date} 7 days
${day_of_week}= Convert Date ${next_week} result_format=%A
${day_of_week_fr}= Evaluate """${day_of_week}""".title()
${day}= Convert Date ${next_week} result_format=%d
${month}= Convert Date ${next_week} result_format=%B
[Return] ${day_of_week_fr} ${day} ${month}
test
${val}= Get Next Week French date
Log To Console ${val}
*** Test Cases ***
MY SUPER TEST
[Tags] foo|AC0
Given test
On my local machine (Windows 7) OK:
Evaluate locale.setlocale(locale.LC_ALL, 'french') locale
On my CI machine (Unix) OK:
Evaluate locale.setlocale(locale.LC_ALL, 'fr_FR.UTF-8') locale
If I use fr_FR.UTF-8
on my local machine, I have this error:
locale.setlocale(locale.LC_ALL, 'fr_FR.UTF-8')' failed: unsupported locale setting
EDIT
May be Python 2 (fr_FR.UTF-8) Vs. Python 3 (french) ??