Skip to content

Commit adbcab9

Browse files
committed
Invigorate testing procedures
1 parent df0b73a commit adbcab9

File tree

2 files changed

+192
-94
lines changed

2 files changed

+192
-94
lines changed

src/tests/math/test_linspace.f90

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ subroutine test_linspace_sp
4747
real(sp) :: true_difference
4848

4949
integer :: i
50-
real(sp), dimension(:), allocatable :: x
50+
real(sp), allocatable :: x(:)
5151

5252
x = linspace(start, end, n)
5353

@@ -77,7 +77,7 @@ subroutine test_linspace_dp
7777
real(dp) :: expected_interval
7878
real(dp) :: true_difference
7979

80-
real(dp), dimension(:), allocatable :: x
80+
real(dp), allocatable :: x(:)
8181
integer :: i
8282

8383
x = linspace(start, end)
@@ -103,7 +103,7 @@ subroutine test_linspace_neg_index
103103
real(dp) :: start = 1.0_dp
104104
real(dp) :: end = 10.0_dp
105105

106-
real(dp), dimension(:), allocatable :: x
106+
real(dp), allocatable :: x(:)
107107

108108
x = linspace(start, end, -15)
109109

@@ -118,7 +118,7 @@ subroutine test_linspace_cmplx
118118
complex(dp) :: expected_interval
119119
integer, parameter :: n = 10
120120

121-
complex(dp) :: z(n)
121+
complex(dp), allocatable :: z(:)
122122

123123
integer :: i
124124

@@ -157,7 +157,7 @@ subroutine test_linspace_cmplx_2
157157

158158
integer, parameter :: n = 5
159159

160-
complex(dp) :: z(n)
160+
complex(dp), allocatable :: z(:)
161161

162162
integer :: i
163163

@@ -196,7 +196,7 @@ subroutine test_linspace_cmplx_3
196196

197197
integer, parameter :: n = 20
198198

199-
complex(dp) :: z(n)
199+
complex(dp), allocatable :: z(:)
200200

201201
integer :: i
202202

@@ -235,7 +235,7 @@ subroutine test_linspace_cmplx_sp
235235

236236
integer, parameter :: n = 10
237237

238-
complex(sp) :: z(n)
238+
complex(sp), allocatable :: z(:)
239239

240240
integer :: i
241241

@@ -276,7 +276,7 @@ subroutine test_linspace_cmplx_sp_2
276276

277277
integer, parameter :: n = DEFAULT_LINSPACE_LENGTH
278278

279-
complex(sp) :: z(n)
279+
complex(sp), allocatable :: z(:)
280280

281281
integer :: i
282282

@@ -318,7 +318,7 @@ subroutine test_linspace_int16
318318

319319
integer, parameter :: n = 6
320320

321-
integer(int16) :: z(n)
321+
integer(int16), allocatable :: z(:)
322322

323323
integer :: i
324324

@@ -358,7 +358,7 @@ subroutine test_linspace_int8
358358

359359
integer, parameter :: n = 10
360360

361-
real(dp) :: z(n)
361+
real(dp), allocatable :: z(:)
362362
integer(int8) :: z_int(n)
363363

364364
integer :: i

0 commit comments

Comments
 (0)