mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-01 13:30:47 +02:00
* improve test so it exits with the proper error code
This commit is contained in:
parent
5bcedcfe30
commit
8aca910435
@ -5,18 +5,24 @@ begin
|
|||||||
yy:=random(0)+1980;
|
yy:=random(0)+1980;
|
||||||
If (yy<1980) or (yy>2099) then
|
If (yy<1980) or (yy>2099) then
|
||||||
res:=1;
|
res:=1;
|
||||||
|
if res<>0 then
|
||||||
|
halt(res);
|
||||||
|
|
||||||
yy:=random(0)+2099;
|
yy:=random(0)+2099;
|
||||||
If (yy<1980) or (yy>2099) then
|
If (yy<1980) or (yy>2099) then
|
||||||
res:=2;
|
res:=2;
|
||||||
|
if res<>0 then
|
||||||
|
halt(res);
|
||||||
|
|
||||||
yy:=random(0)+1980;
|
yy:=random(0)+1980;
|
||||||
If (yy<=1979) or (yy>2099) then
|
If (yy<=1979) or (yy>2099) then
|
||||||
res:=3;
|
res:=3;
|
||||||
|
if res<>0 then
|
||||||
|
halt(res);
|
||||||
|
|
||||||
yy:=random(0)+2099;
|
yy:=random(0)+2099;
|
||||||
If (yy<1979) or (yy>=2100) then
|
If (yy<1979) or (yy>=2100) then
|
||||||
res:=4;
|
res:=4;
|
||||||
|
if res<>0 then
|
||||||
halt(res);
|
halt(res);
|
||||||
end.
|
end.
|
Loading…
Reference in New Issue
Block a user