
    BwgU                     T   d dl Z d dlZd dlmZmZmZ d dlZd dlm	Z	 e j                  j                   G d de	j                               Z G d de	j                        Z G d d	e	j                        Z G d
 de	j                        Z G d de	j                        Ze j                  j                   G d de	j                               Ze j                  j                   G d de	j                               Ze j                  j                   G d de	j                               Zy)    N)assert_array_equalassert_equalassert_raises)utilc                      e Zd ZdZdZg dZdZeD ]  ZeZ e	d      j                  ee      Ze ej                  dj                  g de de d	e d
e de de de d	e de de de de de de de de de de de de de de de de de d            z  Z ej                   j#                  de      d        Zej                   j#                  dedd       d        Zej                   j#                  de      d        Zej                   j#                  de      d        Zej                   j#                  de      d        Zy)TestCharacterString.f90test_character_string13star (*))r   z

        subroutine _input_z(c, o, n)
          character*z, intent(in) :: c
          integer n
          !f2py integer, depend(c), intent(hide) :: n = slen(c)
          integer*1, dimension(n) :: o
          !f2py intent(out) o
          o = transfer(c, o)
        end subroutine _output_z, intent(out) :: c
          integer n
          integer*1, dimension(n), intent(in) :: o
          !f2py integer, depend(o), intent(hide) :: n = len(o)
          c = transfer(o, c)
        end subroutine _array_input_z;(c, o, m, n)
          integer m, i, n
          character*aH  , intent(in), dimension(m) :: c
          !f2py integer, depend(c), intent(hide) :: m = len(c)
          !f2py integer, depend(c), intent(hide) :: n = f2py_itemsize(c)
          integer*1, dimension(m, n), intent(out) :: o
          do i=1,m
            o(i, :) = transfer(c(i), o(i, :))
          end do
        end subroutine _array_output_z!(c, o, m, n)
          character*a  , intent(out), dimension(m) :: c
          integer n
          integer*1, dimension(m, n), intent(in) :: o
          !f2py character(f2py_len=n) :: c
          !f2py integer, depend(o), intent(hide) :: m = len(o)
          !f2py integer, depend(o), intent(hide) :: n = shape(o, 1)
          do i=1,m
            c(i) = transfer(o(i, :), c(i))
          end do
        end subroutine _2d_array_input_zH(c, o, m1, m2, n)
          integer m1, m2, i, j, n
          character*a  , intent(in), dimension(m1, m2) :: c
          !f2py integer, depend(c), intent(hide) :: m1 = len(c)
          !f2py integer, depend(c), intent(hide) :: m2 = shape(c, 1)
          !f2py integer, depend(c), intent(hide) :: n = f2py_itemsize(c)
          integer*1, dimension(m1, m2, n), intent(out) :: o
          do i=1,m1
            do j=1,m2
              o(i, j, :) = transfer(c(i, j), o(i, j, :))
            end do
          end do
        end subroutine z	
        lengthc                    ddij                  ||      }t        | j                  | j                  dz   |z         }dddd|   }t	         ||      t        j                  t        t        t        |            d	             y )
Nr   r   r   aabcabcdeabcdeabcder   u1dtype)
getgetattrmodulefprefixr   nparraylistmapordselfr   fsuffixfr   s        V/var/www/horilla/myenv/lib/python3.12/site-packages/numpy/f2py/tests/test_character.py
test_inputzTestCharacterString.test_inputM   sk    &/%%ff5DKK	!9G!CDE;7?1Q4$s3{*;4!HI    Nc                     |}t        | j                  | j                  dz   |z         }ddd|   }t         |t	        j
                  t        t        t        |            d            |j                                y )Nr   r   r   )r   r   r   r   )
r   r    r!   r   r"   r#   r$   r%   r&   encoder'   s        r+   test_outputzTestCharacterString.test_outputV   sb    DKK
!:W!DEE"6*1RXXd3sA;&7tDE88:	'r-   c                 ,   |}t        | j                  | j                  dz   |z         }t        j                  dddd|   dddd|   gd	
      }t        j                  |D cg c]  }t        |       c}d
      }t         ||      |       y c c}w )Nr   r   r   r   r   AABCABCDEABCDEABCDESr   r   r   r    r!   r"   r#   r$   r   )r(   r   r)   r*   r   sexpecteds          r+   test_array_inputz$TestCharacterString.test_array_input`   s    DKK!?'!IJHHCe[A&Ie[A&I"$ 88a0T!W0=1Q4* 1   #Bc                 ,   |}t        | j                  | j                  dz   |z         }t        j                  dddd|   dddd|   gd	
      }t        j                  |D cg c]  }t        |       c}d
      }t         ||      |       y c c}w )Nr   r   r   r   r   r3   r4   r5   r6   r   r   r7   )r(   r   r)   r*   r9   r8   r   s          r+   test_array_outputz%TestCharacterString.test_array_outputl   s    DKK0@!@7!JK88UK8@UK8@BILN HHx0!d1g0=1Q4* 1r;   c                 ~   |}t        | j                  | j                  dz   |z         }t        j                  dddd|   dddd|   gd	d
dd|   dddd|   ggd      }t        j                  |D cg c]  }|D cg c]  }t        |       c} c}}dd      }t         ||      |       y c c}w c c}}w )Nr   r   r   r   r   r3   r4   r5   r*   fghfghijfghijfghijFFGHFGHIJFGHIJFGHIJr6   r   r   r   orderr7   )r(   r   r)   r*   r   rowitemr9   s           r+   test_2d_array_inputz'TestCharacterString.test_2d_array_inputx   s    DKK0B!BW!LMHHSukB6J ukB6JL ukB6J ukB6JLM 	 
 88QGcS9Td4j9G"&c31Q4* :Gs   6	B9
?B4B9
4B9
)__name__
__module____qualname__suffixr!   length_listcoder   r)   dictr   clengthtextwrapdedentjoinpytestmarkparametrizer,   r1   r:   r=   rH    r-   r+   r   r      sm    F%G$KD ;E"&&vv6 7! 7! % 7!97!#7!$+97!-7! I7!7!  y7! !(7! )0y7!17! 97! %7! &-I7!.7! I7!7!"  y#7!" !)#7!" *1	#7!"2#7!& 9'7!& *'7!& +2'7!&3'7!* I+7!*+7!8  y97!8 !.97!8 /6Y97!8797!< 9=7!< +=7!< ,3)=7!<4=7!> I?7!>	?7!P  yQ7!P !/Q7!P 07iQ7!P8Q7!T 9U7!T -U7!T .5IU7!T6U7!X IY7!X
Y7!l  ym7!l !1m7!l 29	m7!l:	m7! 7 7		;z [[X{3J 4J [[X{3B'78' 9' [[X{3	+ 4	+ [[X{3	+ 4	+ [[X{3+ 4+r-   r   c                   l   e Zd ZdZdZ ej                  dj                  g de de de de de d	e d
e de de de de de de de de de de de de de de de de de d            Ze	j                  j                  dddg      d         Zd! Ze	j                  j                  dg d"      d#        Zd$ Ze	j                  j                  dg d"      d%        Zd& Zd' Zd( Ze	j                  j                  dddg      d)        Zd* Ze	j                  j                  dddg      d+        Ze	j                  j                  dddg      d,        Zd- Ze	j                  j3                  d.      d/        Zd0 Zy1)2TestCharacterr	   test_characterr   
       subroutine z_input(c, o)
          character, intent(in) :: c
          integer*1 o
          !f2py intent(out) o
          o = transfer(c, o)
       end subroutine z_input

       subroutine z_output(c, o)
          character :: c
          integer*1, intent(in) :: o
          !f2py intent(out) c
          c = transfer(o, c)
       end subroutine z_output

       subroutine z_input_output(c, o)
          character, intent(in) :: c
          character o
          !f2py intent(out) o
          o = c
       end subroutine z!_input_output

       subroutine z_inout(c, n)
          character :: c, n
          !f2py intent(in) n
          !f2py intent(inout) c
          c = n
       end subroutine z_inout

       function z_return(o) result (c)
          character :: c
          character, intent(in) :: o
          c = transfer(o, c)
       end function z_return

       subroutine z_array_input(c, o)
          character, intent(in) :: c(3)
          integer*1 o(3)
          !f2py intent(out) o
          integer i
          do i=1,3
            o(i) = transfer(c(i), o(i))
          end do
       end subroutine z _array_input

       subroutine a'  _2d_array_input(c, o)
          character, intent(in) :: c(2, 3)
          integer*1 o(2, 3)
          !f2py intent(out) o
          integer i, j
          do i=1,2
            do j=1,3
              o(i, j) = transfer(c(i, j), o(i, j))
            end do
          end do
       end subroutine z#_2d_array_input

       subroutine z_array_output(c, o)
          character :: c(3)
          integer*1, intent(in) :: o(3)
          !f2py intent(out) c
          do i=1,3
            c(i) = transfer(o(i), c(i))
          end do
       end subroutine z!_array_output

       subroutine z_array_inout(c, n)
          character :: c(3), n(3)
          !f2py intent(in) n(3)
          !f2py intent(inout) c(3)
          do i=1,3
            c(i) = n(i)
          end do
       end subroutine z _array_inout

       subroutine a   _2d_array_inout(c, n)
          character :: c(2, 3), n(2, 3)
          !f2py intent(in) n(2, 3)
          !f2py intent(inout) c(2. 3)
          integer i, j
          do i=1,2
            do j=1,3
              c(i, j) = n(i, j)
            end do
          end do
       end subroutine z!_2d_array_inout

       function z_array_return(o) result (c)
          character, dimension(3) :: c
          character, intent(in) :: o(3)
          do i=1,3
            c(i) = o(i)
          end do
       end function z_array_return

       function z_optional(o) result (c)
          character, intent(in) :: o
          !f2py character o = "a"
          character :: c
          c = o
       end function z_optional
    r   cS1c                 0   t        | j                  | j                  dz         }t         |t	        j
                  d|            t        d             t         |t	        j
                  d|            t        d             t         |t	        j
                  dg|            t        d             t         |t	        j
                  d|            t        d             t         |t	        j
                  dgg|            t        d             y )N_inputr   r      ar   )r   r    r!   r   r"   r#   r&   r(   r   r*   s      r+   r,   zTestCharacter.test_input   s    DKK!89Qrxx512CH=QrxxE23SX>QrxxU34c#h?QrxxU34c#h?Qrxx#u56CAr-   c                    t        | j                  | j                  dz         }t         |d      t	        d             t         |d      t	        d             t         |d      d       t         |d      d       t         |d      d       t         |d      t	        d             t         |d	      t	        d             t         |dg      t	        d             t         |t        j                  d            t	        d             t         |t        j                  dg            t	        d             t        j                  d      }t         ||      t	        d             t        j                  dg      }t         ||      t	        d             	  |g        t        |j                   d
      # t        $ r%}t        |      j                  d      s Y d }~nd }~ww xY w	  |d       t        |j                   d      # t        $ r%}t        |      j                  d      s Y d }~y d }~ww xY w)Nr_   r   r`   r   r   r-       abs   abz! should have failed on empty listz got 0-lista   z  should have failed on int valuez got int instance)r   r    r!   r   r&   r"   r#   SystemErrorrI   
IndexErrorstrendswith	TypeErrorr(   r*   r   msgs       r+   test_input_variazTestCharacter.test_input_varia   s   DKK!89QsVSX&QtWc$i(QrUAQsVQQuXq!QtWc#h'QuXs3x(QuXs3x(Qrxx~&C1Qrxx'(#c(3HHSMQqT3s8$HHcUOQqT3s8$	PbE
 ,MNOO	  	s8$$]3 4		ObE
 ,LMNN	  	s8$$%89 :	s0   !G 	G/
G**G/3H 	IH<<I)r\   r]   U1c                    t        | j                  | j                  dz         }t         |t	        j
                  g d|            t	        j
                  t        t        t        d            d             t         |t	        j
                  g d|            t	        j
                  t        t        t        d            d             y )N_array_inputr   br\   r   r   i1r`      b   c)	r   r    r!   r   r"   r#   r$   r%   r&   ra   s      r+   r:   zTestCharacter.test_array_input   s    DKK!>?1RXXoUCD88DS%$9F	H1RXX&8FG88DS%$9F	Hr-   c                    t        | j                  | j                  dz         }t         |g d      t	        j
                  t        t        t        d            d             t         |g d      t	        j
                  t        t        t        d            d             	  |g d       t        |j                   d      # t        $ r%}t        |      j                  d	      s Y d }~y d }~ww xY w)
Nrp   rq   r   rs   r   rt   r   rr   r\   d" should have failed on wrong input)th dimension must be fixed to 3 but got 4)r   r    r!   r   r"   r#   r$   r%   r&   rf   rI   
ValueErrorrh   ri   )r(   r*   rl   s      r+   test_array_input_variaz$TestCharacter.test_array_input_varia)  s    DKK!>?1_-88DS%$9F	H1/088DS%$9F	H	C"# ::,@AC C  	s8$$?AA	s   %
C 	C5C00C5c                    t        | j                  | j                  dz         }t        j                  g dg dg|d      }|j                  |dk(  rt        j                  nt        j                        }t         ||      |       y )N_2d_array_inputrq   ry   er*   rA   rD   rn   )	r   r    r!   r"   r#   viewuint32uint8r   )r(   r   r*   r   r9   s        r+   rH   z!TestCharacter.test_2d_array_input:  sf    DKK0A!ABHHo%'.33@66u}"))"((C1Q4*r-   c                     t        | j                  | j                  dz         }t         |t	        d            d       t         |d      d       y )N_outputr`   r   rc   )r   r    r!   r   r&   r(   r*   s     r+   r1   zTestCharacter.test_outputC  s;    DKK	!9:Qs4y\4(QqT5!r-   c           
          t        | j                  | j                  dz         }t         |t	        t        t        d                  t        j                  t	        d      d             y )N_array_outputr   r]   r   )	r   r    r!   r   r$   r%   r&   r"   r#   r   s     r+   r=   zTestCharacter.test_array_outputI  sG    DKK!?@1T#c5/2388DKt<	>r-   c                     t        | j                  | j                  dz         }t         |d      d       t         |d      d       t         |d      d       y )N_input_outputr`   r   r   rc   r   r    r!   r   r   s     r+   test_input_outputzTestCharacter.test_input_outputO  sE    DKK!?@QtWd#QsVT"QrUE"r-   c                    t        | j                  | j                  dz         }t        j                  t        d      |      } ||d       t        |t        j                  t        d      |j                                ||dd  d       t        |t        j                  t        d      |j                               t        j                  dg|      } ||d       t        |t        j                  dg|j                               y )	N_inoutr   r   r3   Abc   BABc)r   r    r!   r"   r#   r$   r   r   )r(   r   r*   r   s       r+   
test_inoutzTestCharacter.test_inoutV  s    DKK!89HHT%[.	!S	1bhhtE{!''BC	!AB%1bhhtE{!''BCHHeWE*	!S	1bhhwagg>?r-   c                    t        | j                  | j                  dz         }t        j                  dd      } ||d       t        |t        j                  d|j                               t        j                  dgd      } ||d       t        |t        j                  dg|j                               	  |dd       t        |j                   d      # t        $ r%}t        |      j                  d      s Y d }~y d }~ww xY w)	Nr   r   S3r   r3   r   z  should have failed on str valuez
 got 3-str)r   r    r!   r"   r#   r   r   rf   rI   r|   rh   ri   rk   s       r+   test_inout_variazTestCharacter.test_inout_variad  s    DKK!89HHU$'	!S	1bhhuAGG<=HHeWD)	!S	1bhhwagg>?	OeSM
 ,LMNN	  	s8$$\2 3	s   =	C 	D'DDc                    t        | j                  | j                  dz         }t        j                  g d|d      }t        j                  g d|d      } |||       t        ||       t        j                  g d|      } ||dd  |       t        |t        j                  g d	|             t        j                  g dg|d      } |||       t        |t        j                  g dg|             t        j                  g d|d      }	  |||       t        |j                   d
      # t        $ r%}t        |      j                  d      s Y d }~y d }~ww xY w)N_array_inoutr3   r   CrA   rD   rq   rx   r   r   )r   r3   r   r   rz   r{   )r   r    r!   r"   r#   r   rf   rI   r|   rh   ri   )r(   r   r*   nr   rl   s         r+   test_array_inoutzTestCharacter.test_array_inoutv  s1   DKK!>?HH_E=HH_E=	!Q1a HH)7	!AB%1bhh';5IJHHo&e3?	!Q1bhh'8FGHH)cB	CaG ::,@AC C  	s8$$?AA	s   	D9 9	E'E""E'c                     t        | j                  | j                  dz         }t        j                  g dg dg|d      }t        j                  g dg dg|d      } |||       t        ||       y )N_2d_array_inoutr   )DErA   rA   rD   rq   r   r   r    r!   r"   r#   r   )r(   r   r*   r   r   s        r+   test_2d_array_inoutz!TestCharacter.test_2d_array_inout  sm    DKK0A!ABHHo%' - HHo%' - 	
!Q1a r-   c                 n    t        | j                  | j                  dz         }t         |d      d       y )N_returnr   r`   r   r   s     r+   test_returnzTestCharacter.test_return  s)    DKK	!9:QsVT"r-   z*fortran function returning array segfaultsc                     t        | j                  | j                  dz         }t        j                  t        d      d      }t         ||      |       y )N_array_returnr   r]   r   r7   )r(   r*   r   s      r+   test_array_returnzTestCharacter.test_array_return  s=    DKK!?@HHT%[-1Q4#r-   c                     t        | j                  | j                  dz         }t         |       d       t         |d      d       y )N	_optionalr`      Br   r   s     r+   test_optionalzTestCharacter.test_optional  s5    DKK!;<QS$QtWd#r-   N)rI   rJ   rK   rL   r!   rQ   rR   rS   rN   rT   rU   rV   r,   rm   r:   r}   rH   r1   r=   r   r   r   r   r   r   skipr   r   rW   r-   r+   rY   rY      s   FG8?? e e   e)ee ie e )ee ie e )ee( i)e( )e, )-e,-e6 i7e6 7e: 	;e:;eB ICeBCeF )GeFGeV iWeV WeZ )[eZ
[en ioen oer )serse@ iAe@ AeD )EeDEeR iSeR SeV )WeV
Wej ikej ken 	oenoez I{ez{e~ 	e~eH IIeHIe e	DN [[WsDk2B 3B!OF [[W&78H 9HC" [[W&78+ 9+"># [[WsDk2@ 3@O$ [[WsDk2C 3C6 [[WsDk2	! 3	!#
 [[BC$ D$$r-   rY   c                      e Zd ZdZdZ ej                  de de de de de de d	e d
e de de de de d      Zej                  j                  d        Zd Zd Zd Zej                  j                  dddg      d        Zy)TestMiscCharacterr	   test_misc_characterr[   a(  _gh18684(x, y, m)
         character(len=5), dimension(m), intent(in) :: x
         character*5, dimension(m), intent(out) :: y
         integer i, m
         !f2py integer, intent(hide), depend(x) :: m = f2py_len(x)
         do i=1,m
           y(i) = x(i)
         end do
       end subroutine z_gh18684

       subroutine z_gh6308(x, i)
         integer i
         !f2py check(i>=0 && i<12) i
         character*5 name, x
         common name(12)
         name(i + 1) = x
       end subroutine z_gh6308

       subroutine z_gh4519(x)
         character(len=*), intent(in) :: x(:)
         !f2py intent(out) x
         integer :: i
         ! Uncomment for debug printing:
         !do i=1, size(x)
         !   print*, "x(",i,")=", x(i)
         !end do
       end subroutine z_gh4519

       pure function aq  _gh3425(x) result (y)
         character(len=*), intent(in) :: x
         character(len=len(x)) :: y
         integer :: i
         do i = 1, len(x)
           j = iachar(x(i:i))
           if (j>=iachar("a") .and. j<=iachar("z") ) then
             y(i:i) = achar(j-32)
           else
             y(i:i) = x(i:i)
           endif
         end do
       end function z_gh3425

       subroutine aO  _character_bc_new(x, y, z)
         character, intent(in) :: x
         character, intent(out) :: y
         !f2py character, depend(x) :: y = x
         !f2py character, dimension((x=='a'?1:2)), depend(x), intent(out) :: z
         character, dimension(*) :: z
         !f2py character, optional, check(x == 'a' || x == 'b') :: x = 'a'
         !f2py callstatement (*f2py_func)(&x, &y, z)
         !f2py callprotoargument character*, character*, character*
         if (y.eq.x) then
           y = x
         else
           y = 'e'
         endif
         z(1) = 'c'
       end subroutine z%_character_bc_new

       subroutine aG  _character_bc_old(x, y, z)
         character, intent(in) :: x
         character, intent(out) :: y
         !f2py character, depend(x) :: y = x[0]
         !f2py character, dimension((*x=='a'?1:2)), depend(x), intent(out) :: z
         character, dimension(*) :: z
         !f2py character, optional, check(*x == 'a' || x[0] == 'b') :: x = 'a'
         !f2py callstatement (*f2py_func)(x, y, z)
         !f2py callprotoargument char*, char*, char*
          if (y.eq.x) then
           y = x
         else
           y = 'e'
         endif
         z(1) = 'c'
       end subroutine z_character_bc_old
    c                     t        | j                  | j                  dz         }t        j                  ddgd      } ||      }t        ||       y )N_gh18684abcdefghijS5r   r   )r(   r*   xys       r+   test_gh18684zTestMiscCharacter.test_gh18684  sE     DKK
!:;HHgw't4aD1a r-   c                    t        | j                  | j                  dz         }t        | j                  j                  j
                  j                  t        j                  d             t        t        | j                  j                  j
                        d        |dd       t        | j                  j                  j
                  d   d        |dd       t        | j                  j                  j
                  d   d	       y )
N_gh6308r      r   r   s   abcde12345   s   12345)	r   r    r!   r   _BLNK_namer   r"   lenr   s     r+   test_gh6308zTestMiscCharacter.test_gh6308  s    DKK	!9:T[['',,22BHHTNCS++00126	'1T[['',,Q/:	'1T[['',,Q/:r-   c                 J   t        | j                  | j                  dz         }dt        dt	        j
                  d            fdt        dt	        j
                  d            ft	        j                  g dd	      t        d
t	        j
                  d            fg dt        d
t	        j
                  d            fddgt        dt	        j
                  d            ffD ];  \  }} ||      }|j                         D ]  \  }}t        t        ||      |        = y )N_gh4519r   rW   r]   )shaper   textS4)r   2r   r   )   )r   r   34S2r   )   )	r   r    r!   rO   r"   r   r#   itemsr   )r(   r*   r   r9   rkvs          r+   test_gh4519zTestMiscCharacter.test_gh4519  s    DKK	!9: d288D>:;Bbhhtn=>/6D79!D79b4d"((4.ABD 
	/KAx !A ( /1WQ]A./
	/r-   c                     t        | j                  | j                  dz         }t         |d      d       t         |d      d       t         |d      d       y )N_gh3425abCs   ABCr   r-   abC12ds   ABC12Dr   r   s     r+   test_gh3425zTestMiscCharacter.test_gh3425(  sG    DKK	!9: 	QuXv&QrUC Qx[),r-   statenewoldc                 &   t        | j                  | j                  dz   |z                 \  }}t        |d       t        t	        |      d        d      \  }}t        |d       t        t	        |      d       t        t        fd       y )N_character_bc_r`   r   ru   r   c                        d      S )Nrv   rW   )r*   s   r+   <lambda>z5TestMiscCharacter.test_character_bc.<locals>.<lambda>=  s    4 r-   )r   r    r!   r   r   r   	Exception)r(   r   r\   r   r*   s       @r+   test_character_bcz#TestMiscCharacter.test_character_bc1  st    DKK0@!@5!HIs1QSVQw1QSVQi1r-   N)rI   rJ   rK   rL   r!   rQ   rR   rN   rT   rU   slowr   r   r   r   rV   r   rW   r-   r+   r   r     s   F#G8??  )  i  )  i  )  i  Y  I )  i  )  i  WL L	D\ [[! !	;/ - [[Wuen52 62r-   r   c                   D    e Zd Z ej                  dddd      gZd Zd Zy)TestStringScalarArrtestssrcstringzscalar_string.f90c                     | j                   j                  j                  | j                   j                  j                  fD ](  }d}|j                  |k(  sJ d}|j
                  |k(  r(J  y )NrW   z|S8)r    string_testr   string77r   r   r(   outr9   s      r+   	test_charzTestStringScalarArr.test_charC  sg    KK++22KK++446 	)CH99(((H99(((	)r-   c                     | j                   j                  j                  | j                   j                  j                  fD ](  }d}|j                  |k(  sJ d}|j
                  |k(  r(J  y )N)r      z|S12)r    r   strarrstrarr77r   r   r   s      r+   test_char_arrz!TestStringScalarArr.test_char_arrK  sg    KK++22KK++446 	)CH99(((H99(((	)r-   N)rI   rJ   rK   r   getpathsourcesr   r   rW   r-   r+   r   r   @  s&    t||GUH6IJKG))r-   r   c                   >    e Zd Z ej                  dddd      gZd Zy)TestStringAssumedLengthr   r   r   z	gh24008.fc                 <    | j                   j                  dd       y )Njoebob)r    greet)r(   s    r+   test_gh24008z$TestStringAssumedLength.test_gh24008V  s    %'r-   N)rI   rJ   rK   r   r   r   r   rW   r-   r+   r   r   S  s     t||GUHkBCG(r-   r   c                   >    e Zd Z ej                  dddd      gZd Zy)TestStringOptionalInOutr   r   r   zgh24662.f90c                 v   | j                   j                          t        j                  dd      }| j                   j                  |       d|j	                         j                         v sJ t        j                  t              5  d}| j                   j                  |       d d d        y # 1 sw Y   y xY w)NhiS32r   zoutput stringHi)	r    string_inout_optionalr"   r#   tobytesdecoderT   raisesr   )r(   r   aas      r+   test_gh24662z$TestStringOptionalInOut.test_gh24662]  s    ))+HHT'))!,!))+"4"4"6666]]9% 	2BKK--b1	2 	2 	2s   B//B8N)rI   rJ   rK   r   r   r   r  rW   r-   r+   r   r   Y  s     t||GUHmDEG2r-   r   c                   j    e Zd Z ej                  dddd       ej                  dddd      gZdZd Zy)	TestNewCharHandlingr   r   r   zgh25286.pyfgh25286.f90_char_handling_testc                 H    | j                   j                  d      }|dk(  sJ y NTr   r    charintr(   infos     r+   test_gh25286z TestNewCharHandling.test_gh25286p  "    {{""3'qyyr-   NrI   rJ   rK   r   r   r   module_namer  rW   r-   r+   r  r  g  s?     	WeX}=WeX}=G (Kr-   r  c                   j    e Zd Z ej                  dddd       ej                  dddd      gZdZd Zy)	TestBCCharHandlingr   r   r   zgh25286_bc.pyfr  r	  c                 H    | j                   j                  d      }|dk(  sJ y r  r  r  s     r+   r  zTestBCCharHandling.test_gh25286}  r  r-   Nr  rW   r-   r+   r  r  t  s@     	WeX/?@WeX}=G (Kr-   r  )rT   rQ   numpy.testingr   r   r   numpyr"   numpy.f2py.testsr   rU   r   F2PyTestr   rY   r   r   r   r   r  r  rW   r-   r+   <module>r     s     I I  ! {+$-- {+ {+|g$DMM g$T	L2 L2^)$-- )&(dmm ( 
2dmm 
2 
2 
$-- 
 
 
 
 
r-   