fpc/tests/tbs/tb0503.pp
Jonas Maebe 86649024b3 * fixed fpc_AnsiStr_Concat_multi + test
git-svn-id: trunk@4790 -
2006-10-04 16:44:31 +00:00

42 lines
587 B
ObjectPascal

procedure testansi;
var
s, q: ansistring;
begin
s := 'hell';
s := s+'o';
q := '"';
q := q+'''';
s := s + q + s + 'abc';
if (s <> 'hello"''helloabc') then
halt(1);
s := 'hell';
s := s+'o';
s := q+s+q;
if (s <> '"''hello"''') then
halt(2);
end;
procedure testshort;
var
s, q: shortstring;
begin
s := 'hell';
s := s+'o';
q := '"';
q := q+'''';
s := s + q + s + 'abc';
if (s <> 'hello"''helloabc') then
halt(3);
s := 'hell';
s := s+'o';
s := q+s+q;
if (s <> '"''hello"''') then
halt(4);
end;
begin
testansi;
testshort;
end.