30 character*64 fname, pname1, pname2
31 parameter(fname=
"Unittest_MEDprofile_1.med")
32 parameter(pname1=
"Profile name1")
33 parameter(pname2=
"Profile name 2")
35 parameter(psize1=4, psize2=2)
36 integer profile1(4), profile2(2)
37 data profile1 /1,2, 3,4/
47 call mfiope(fid,fname,med_acc_rdonly,cret)
49 if (cret .ne. 0 )
then 50 print *,
'ERROR : open file' 59 if (cret .ne. 0 )
then 60 print *,
'ERROR : number of profile' 64 print *,
'ERROR : number of profile' 72 call mpfpfi(fid,it,pname,psize,cret)
74 if (cret .ne. 0 )
then 75 print *,
'ERROR : name and size of profile' 79 call mpfprr(fid,pname,profile,cret)
81 if (cret .ne. 0 )
then 82 print *,
'ERROR : read profile' 87 if ((pname .ne. pname2) .or.
88 & (psize .ne. psize2))
then 89 print *,
'ERROR : name and size of profile' 92 if ((profile(1) .ne. profile2(1)) .or.
93 & (profile(2) .ne. profile2(2)))
then 94 print *,
'ERROR : profile array' 100 if ((pname .ne. pname1) .or.
101 & (psize .ne. psize1))
then 102 print *,
'ERROR : name and size of profile' 105 if ((profile(1) .ne. profile1(1)) .or.
106 & (profile(2) .ne. profile1(2)) .or.
107 & (profile(3) .ne. profile1(3)) .or.
108 & (profile(4) .ne. profile1(4)) )
then 109 print *,
'ERROR : profile array' 117 call mpfpsn(fid,pname1,psize,cret)
119 if (cret .ne. 0 )
then 120 print *,
'ERROR : size of profile' 124 if (psize .ne. psize1)
then 125 print *,
'ERROR : size of profile' 129 call mpfpsn(fid,pname2,psize,cret)
131 if (cret .ne. 0 )
then 132 print *,
'ERROR : size of profile' 136 if (psize .ne. psize2)
then 137 print *,
'ERROR : size of profile' 145 if (cret .ne. 0 )
then 146 print *,
'ERROR : close file' subroutine mficlo(fid, cret)
subroutine mpfnpf(fid, n, cret)
subroutine mpfprr(fid, pname, profil, cret)
subroutine mpfpfi(fid, it, pname, psize, cret)
subroutine mfiope(fid, name, access, cret)
subroutine mpfpsn(fid, pname, psize, cret)