--- parser3/tests/157.html 2007/02/28 10:44:56 1.1
+++ parser3/tests/157.html 2007/03/01 10:26:47 1.3
@@ -1,12 +1,36 @@
+$sFrom[157.html]
+$sCopy[newdir1/157.copy]
+$sMove[newdir2/157.move]
^try{
- ^file:copy[157.html;157.copy]
- ^if(-f "157.copy"){
+ Copying file:
+ ^file:copy[$sFrom;$sCopy]
+ ^if(-f $sCopy){
ok.
- ^file:delete[157.copy]
}{
no copy errors but target file doesn't exist.
}
}{
failed.
$exception.handled(1)
-}
\ No newline at end of file
+}
+
+
+^if(-f $sCopy){
+ Moving file:
+ ^try{
+ ^file:move[$sCopy;$sMove]
+ ^if(-f $sMove){
+ ^if(-d ^file:dirname[$sCopy]){
+ moving ok but source dir still exist.
+ }{
+ ok.
+ }
+ ^file:delete[$sMove]
+ }{
+ no move errors but target file doesn't exist.
+ }
+ }{
+ failed.
+ $exception.handled(1)
+ }
+}