관리-도구
편집 파일: _locales.cpython-311.pyc
� �܋f� � �H � d Z ddlZddlZddlZdgZd� Z G d� d� � ZdS )z,Provide class for testing in French locale � N�CommaDecimalPointLocalec � � t j dk rdg} ng d�} t j t j � � }d} | D ]:} t j t j |� � |} n# t j $ r Y �7w xY wt j t j |�� � n%# t j t j |�� � w xY w||fS )a: See if platform has a decimal point as comma locale. Find a locale that uses a comma instead of a period as the decimal point. Returns ------- old_locale: str Locale when the function was called. new_locale: {str, None) First French locale found, None if none found. �win32�FRENCH)�fr_FRzfr_FR.UTF-8�fi_FIzfi_FI.UTF-8N��locale)�sys�platformr � getlocale� LC_NUMERIC� setlocale�Error)�locales� old_locale� new_locale�locs �l/builddir/build/BUILD/cloudlinux-venv-1.0.6/venv/lib64/python3.11/site-packages/numpy/core/tests/_locales.py�find_comma_decimal_point_localer s� � � �|�w����*���B�B�B���!�&�"3�4�4�J��J� ?�� � �C� �� ��!2�C�8�8�8� � �����<� � � ��� ���� ���*�:�>�>�>�>�>�����*�:�>�>�>�>�>�����z�!�!s. �B �!A"� B �"A4�1B �3A4�4B �"B:c �D � e Zd ZdZ e� � \ ZZd� Zd� Zd� Z d� Z dS )r a� Sets LC_NUMERIC to a locale with comma as decimal point. Classes derived from this class have setup and teardown methods that run tests with locale.LC_NUMERIC set to a locale where commas (',') are used as the decimal point instead of periods ('.'). On exit the locale is restored to the initial locale. It also serves as context manager with the same effect. If no such locale is available, the test is skipped. .. versionadded:: 1.15.0 c � � | j �t j d� � t j t j | j �� � d S �NzNo French locale availabler �� tst_locale�pytest�skipr r r ��selfs r �setup_methodz$CommaDecimalPointLocale.setup_method<