blob: 13eb94db21bc724dea6fe0ea0b23bd07516d5b45 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
#!/bin/sh
echo -n $0: 'MAT WRITE... '
cat >test.bas <<'eof'
dim a(3,4)
for i=0 to 3
for j=0 to 4
a(i,j)=i*10+j
print a(i,j);
next
print
next
mat write a
eof
cat >test.ref <<'eof'
0 1 2 3 4
10 11 12 13 14
20 21 22 23 24
30 31 32 33 34
11,12,13,14
21,22,23,24
31,32,33,34
eof
sh ./test/runbas test.bas >test.data
if cmp test.ref test.data
then
rm -f test.*
echo passed
else
echo failed
exit 1
fi
|