Explorar o código

* extended test

git-svn-id: trunk@5005 -
Jonas Maebe %!s(int64=19) %!d(string=hai) anos
pai
achega
9f5a2063a1
Modificáronse 1 ficheiros con 9 adicións e 1 borrados
  1. 9 1
      tests/test/tint2str1.pp

+ 9 - 1
tests/test/tint2str1.pp

@@ -1,14 +1,22 @@
 {$mode macpas}
 
-procedure test(s: string);
+procedure test(const s: string);
 begin
   if s <> 'abcd' then
     halt(1);
 end;
 
+procedure test2(c1,c2,c3,c4: char);
+begin
+  if (c1 <> 'a') or (c2 <> 'b') or (c3 <> 'c') or (c4 <> 'd') then
+    halt(2);
+end;
+
+
 var
   l: longint;
 begin
   l := 'abcd';
   test(l);
+  test2(char(l shr 24),char(l shr 16),char(l shr 8),char(l));
 end.