diff --git a/Inst_eddies/Tests/test_get_1_outerm.f90 b/Inst_eddies/Tests/test_get_1_outerm.f90 index 581144babb56e07d26a8baae0c7b8b9af9148e31..5ed9e0a3e907d1d300036f425425384cb5d4e70e 100644 --- a/Inst_eddies/Tests/test_get_1_outerm.f90 +++ b/Inst_eddies/Tests/test_get_1_outerm.f90 @@ -59,6 +59,7 @@ program test_get_1_outerm TYPE(shpfileobject) hshp_cont_list namelist /main_nml/ ind_targ_extr, innermost_level, cyclone, date, & grid_lon_lat + logical exist !---------------------------------------------------------------- @@ -68,8 +69,16 @@ program test_get_1_outerm write(unit = *, nml = main_nml) call config call input_ssh(corner, step, periodic, ssh, u, v) - call csvread("outside_points.csv", outside_points, first_r = 3) - outside_points = transpose(outside_points) * deg_to_rad + inquire(file = "outside_points.csv", exist = exist) + + if (exist) then + call csvread("outside_points.csv", outside_points, first_r = 3) + outside_points = transpose(outside_points) * deg_to_rad + else + print *, '"outside_points.csv" not found. Assuming no outside points...' + allocate(outside_points(2, 0)) + end if + e%extr%coord_proj = ind_targ_extr e%extr%coord = corner + (ind_targ_extr - 1) * step call get_1_outerm(e%out_cont, cont_list, n_cont, cyclone, e%extr%coord, &