1j d Z ddlZddlZddlmZmZmZ G d d Z G d d Z G d d Z ej ej ej ej ej gZej ej ej ej ej gZej ej ej ej gZej ej ej gZ G d d Z ej! " dd ej# d ej$ d ej% g d Z&ej! " dd ej$ d g d Z'd Z(d Z)ej! " dd ej# d ej$ d ej% g d Z*d Z+d Z,dS )z; Test the scalar constructors, which also do type-coercion N)assert_equalassert_almost_equalassert_warnsc e Zd Zd Zd ZdS )TestFromStringc t j d }t j d }t j d }t |d t |d t |d d S )Nz1.234gX9v?)npsingledouble longdoubler )selffsinglefdoubleflongdoubles v/builddir/build/BUILD/cloudlinux-venv-1.0.11/venv/lib64/python3.11/site-packages/numpy/core/tests/test_scalar_ctors.py test_floatingzTestFromString.test_floating se )G$$)G$$mG,,GU+++GU+++K///// c t j d }t |t j t j d }t |t j t j d }t |t j t t t j d }t |t j t j d }t |t j t j d }t |t j t j d }t |t j t t t j d }t |t j dS )z6 Strings containing an unrepresentable float overflow 1e10000z-1e10000N) r halfr infr r r RuntimeWarningr )r fhalfr r r s r test_floating_overflowz%TestFromString.test_floating_overflow s ""UBF###)I&&Wbf%%%)I&&Wbf%%%">2=)LL["&))) ##URVG$$$)J''Wrvg&&&)J''Wrvg&&&">2=*MM[26'*****r N)__name__ __module____qualname__r r r r r r s2 0 0 0+ + + + +r r c &