3 # Tests for the MOVE protocol command.
8 .
$AM_SRCDIR/import-common.sh
12 cat >$OUTDIR/config
<< EOF
18 passphrase_file=$WDIR/passphrase.key
20 mv -f data
/list data
/move || bail_out
"Could not move data/list."
25 run_pwmc
"move" $DEVNULL <<EOF
28 test_failure
$test_n $?
536903715 "Fail to move src to src."
32 run_pwmc
"move" $DEVNULL <<EOF
35 test_failure
$test_n $?
536871048 "Fail to move non-existent element."
39 run_pwmc
"move" $DEVNULL <<EOF
42 test_failure
$test_n $?
536903715 "Fail to move child with target to root of same node."
46 run_pwmc
"-S move" $DEVNULL <<EOF
50 test_result
$test_n $? move
"Move child to sibling child with target."
54 run_pwmc
"-S move" $DEVNULL <<EOF
58 test_result
$test_n $? move
"Move child with target to parent sibling."
62 run_pwmc
"-S move" $DEVNULL <<EOF
66 test_result
$test_n $? move
"Overwrite existing root tree."
70 run_pwmc
"-S move" $DEVNULL <<EOF
74 test_result
$test_n $? move
"Show child elements whose target contains an error."
78 run_pwmc
"-S move" $DEVNULL <<EOF
82 test_result
$test_n $? move
"Move node whose target value is a document root node."
86 run_pwmc
"-S move" $DEVNULL <<EOF
90 test_result
$test_n $? move
"Move node whose target value is a parent."
94 run_pwmc
"-S move" $DEVNULL <<EOF
98 test_result
$test_n $? move
"Create new path from non-existing dest."