Browse Source

* FExpand bug

peter 23 years ago
parent
commit
09ccea65cb
1 changed files with 30 additions and 0 deletions
  1. 30 0
      tests/webtbs/tw1964.pp

+ 30 - 0
tests/webtbs/tw1964.pp

@@ -0,0 +1,30 @@
+  uses  DOS;
+  var
+    error : boolean;
+
+  procedure Expand(FileMask: string);
+    var
+      FileMaskOut : string;
+    begin
+      WriteLn;
+      WriteLn('Expanding "',FileMask,'"');
+      FileMaskOut := FExpand(FileMask);
+      WriteLn('To become "',FileMaskOut,'"');
+      if FileMask<>FileMaskOut then
+       error:=true;
+    end;
+  begin
+{$ifdef Win32}
+    Expand('C:\Windows1\System');
+    Expand('\\.\C\Windows1\System');
+    Expand('C:\Windows1\System');
+    if error then
+     begin
+       Writeln('ERROR!');
+       Halt(1);
+     end;
+{$else}
+   Writeln('Win32 only test');
+{$endif}
+  end.
+