From 0b2c6b3800e1918da563c3d2847afc6c5cd6a6d2 Mon Sep 17 00:00:00 2001 From: Ben Kibbey Date: Wed, 17 Sep 2014 18:27:17 -0400 Subject: [PATCH] Add test for commit 5a54b96. --- tests/Makefile.am | 4 ++-- tests/{acl.result2 => acl.result11} | 0 tests/acl.test | 2 +- tests/copy.result1 | 6 +++++- tests/copy.result2 | 4 ++++ tests/copy.result3 | 4 ++++ tests/copy.result4 | 4 ++++ tests/copy.result5 | 4 ++++ tests/copy.result6 | 4 ++++ tests/list.result1 | 4 +++- tests/list.result2 | 4 +++- tests/list.result3 | 4 +++- tests/list.result4 | 6 +++++- tests/list.xml | 2 ++ tests/move.result4 | 6 +++++- tests/move.result5 | 6 +++++- tests/move.result6 | 4 ++++ tests/move.result7 | 6 +++++- tests/{move.result7 => move.result8} | 6 +++++- tests/{move.result7 => move.result9} | 6 +++++- tests/move.test | 14 ++++++++++++++ tests/rename.result3 | 6 +++++- tests/rename.result4 | 6 +++++- tests/xpath.result4 | 6 +++++- 24 files changed, 102 insertions(+), 16 deletions(-) rename tests/{acl.result2 => acl.result11} (100%) copy tests/{move.result7 => move.result8} (88%) copy tests/{move.result7 => move.result9} (90%) diff --git a/tests/Makefile.am b/tests/Makefile.am index 437d9a7a..b1efc46f 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -5,14 +5,14 @@ EXTRA_DIST= common.sh convert.result convert-v2x.test datafile.key \ store.result7 store.result10 store.result11 \ store.result15 list.test list.xml list.key list.result1 \ list.result2 list.result3 list.result4 list.result5 move.test \ - move.result4 move.result5 move.result6 move.result7 \ + move.result4 move.result5 move.result6 move.result7 move.result8 \ import-common.sh copy.test copy.result1 copy.result2 copy.result3 \ copy.result4 copy.result5 copy.result6 rename.test rename.result3 \ rename.result4 realpath.test realpath.result2 realpath.result3 \ import.test import.result2 import.result3 import.result4 \ import.result5 import.result6 import.result7 xpath.result3 \ xpath.result4 xpath.test convert-v2x-use-agent.test \ - acl.test acl.xml acl.key acl.result1 acl.result2 + acl.test acl.xml acl.key acl.result1 acl.result11 move.result9 tests: $(MAKE) -C $(top_srcdir)/src diff --git a/tests/acl.result2 b/tests/acl.result11 similarity index 100% rename from tests/acl.result2 rename to tests/acl.result11 diff --git a/tests/acl.test b/tests/acl.test index fec609c7..0dac4b09 100755 --- a/tests/acl.test +++ b/tests/acl.test @@ -91,7 +91,7 @@ echo echo "Test 11. Create parent element content." echo -ne 'acl\tacl value' | pwmc $PWMC_ARGS --inquire STORE -S acl echo -ne 'GET acl' | pwmc $PWMC_ARGS acl > result -cmp acl.result2 result +cmp acl.result11 result rm -f result test_success diff --git a/tests/copy.result1 b/tests/copy.result1 index 55e90c00..07a30ca8 100644 --- a/tests/copy.result1 +++ b/tests/copy.result1 @@ -34,4 +34,8 @@ target-loop-b O !c !d !e !c !e !d + -!d !e \ No newline at end of file +!d !e +!x + +!x !y +!x y T !z +!z \ No newline at end of file diff --git a/tests/copy.result2 b/tests/copy.result2 index ab66c218..2351a0cd 100644 --- a/tests/copy.result2 +++ b/tests/copy.result2 @@ -35,6 +35,10 @@ target-loop-b O !c !e !d + !d !e +!x + +!x !y +!x y T !z +!z !new + !new !b + !new !b !c diff --git a/tests/copy.result3 b/tests/copy.result3 index 3f1942ce..636175af 100644 --- a/tests/copy.result3 +++ b/tests/copy.result3 @@ -57,6 +57,10 @@ target-loop-b O !c !e !d + !d !e +!x + +!x !y +!x y T !z +!z !new + !new !b + !new !b !c diff --git a/tests/copy.result4 b/tests/copy.result4 index ab66c218..2351a0cd 100644 --- a/tests/copy.result4 +++ b/tests/copy.result4 @@ -35,6 +35,10 @@ target-loop-b O !c !e !d + !d !e +!x + +!x !y +!x y T !z +!z !new + !new !b + !new !b !c diff --git a/tests/copy.result5 b/tests/copy.result5 index 1ae73da2..dfc3a6d8 100644 --- a/tests/copy.result5 +++ b/tests/copy.result5 @@ -41,6 +41,10 @@ target-loop-b O !c !e !d + !d !e +!x + +!x !y +!x y T !z +!z !new + !new !b + !new !b !c diff --git a/tests/copy.result6 b/tests/copy.result6 index ab66c218..2351a0cd 100644 --- a/tests/copy.result6 +++ b/tests/copy.result6 @@ -35,6 +35,10 @@ target-loop-b O !c !e !d + !d !e +!x + +!x !y +!x y T !z +!z !new + !new !b + !new !b !c diff --git a/tests/list.result1 b/tests/list.result1 index 7181dedc..b6dbbd75 100644 --- a/tests/list.result1 +++ b/tests/list.result1 @@ -8,4 +8,6 @@ target-loop-a !target-loop-b target-loop-b !c -!d \ No newline at end of file +!d +!x +!z \ No newline at end of file diff --git a/tests/list.result2 b/tests/list.result2 index 2d01544d..f80ba40d 100644 --- a/tests/list.result2 +++ b/tests/list.result2 @@ -8,4 +8,6 @@ target-loop-a O !target-loop-b target-loop-b O !c + -!d + \ No newline at end of file +!d + +!x + +!z \ No newline at end of file diff --git a/tests/list.result3 b/tests/list.result3 index a6c0e888..f77a2a39 100644 --- a/tests/list.result3 +++ b/tests/list.result3 @@ -8,4 +8,6 @@ target-loop-a O !target-loop-b target-loop-b O !c + -!d + \ No newline at end of file +!d + +!x + +!z \ No newline at end of file diff --git a/tests/list.result4 b/tests/list.result4 index 55e90c00..07a30ca8 100644 --- a/tests/list.result4 +++ b/tests/list.result4 @@ -34,4 +34,8 @@ target-loop-b O !c !d !e !c !e !d + -!d !e \ No newline at end of file +!d !e +!x + +!x !y +!x y T !z +!z \ No newline at end of file diff --git a/tests/list.xml b/tests/list.xml index 1024b7e3..8ba11671 100644 --- a/tests/list.xml +++ b/tests/list.xml @@ -11,4 +11,6 @@ c d e valuec d valuec e valuec value d e valued value + y value + z value diff --git a/tests/move.result4 b/tests/move.result4 index 33abf062..f4d9e6bb 100644 --- a/tests/move.result4 +++ b/tests/move.result4 @@ -38,4 +38,8 @@ target-loop-b O !d + !d !e + !d !e !c + -!d !e !c !d \ No newline at end of file +!d !e !c !d +!x + +!x !y +!x y T !z +!z \ No newline at end of file diff --git a/tests/move.result5 b/tests/move.result5 index 55e90c00..07a30ca8 100644 --- a/tests/move.result5 +++ b/tests/move.result5 @@ -34,4 +34,8 @@ target-loop-b O !c !d !e !c !e !d + -!d !e \ No newline at end of file +!d !e +!x + +!x !y +!x y T !z +!z \ No newline at end of file diff --git a/tests/move.result6 b/tests/move.result6 index c196eccb..84fb68eb 100644 --- a/tests/move.result6 +++ b/tests/move.result6 @@ -21,6 +21,10 @@ target-loop-a O target-loop-b O !c + !c !e +!x + +!x !y +!x y T !z +!z !d + !d !e d O \ No newline at end of file diff --git a/tests/move.result7 b/tests/move.result7 index 4c0d9f64..b731b1e0 100644 --- a/tests/move.result7 +++ b/tests/move.result7 @@ -29,4 +29,8 @@ target-loop-b O !c !e + !c !e !d + !c !e d E -!c !e !d !e \ No newline at end of file +!c !e !d !e +!x + +!x !y +!x y T !z +!z \ No newline at end of file diff --git a/tests/move.result7 b/tests/move.result8 similarity index 88% copy from tests/move.result7 copy to tests/move.result8 index 4c0d9f64..9d66e3d5 100644 --- a/tests/move.result7 +++ b/tests/move.result8 @@ -29,4 +29,8 @@ target-loop-b O !c !e + !c !e !d + !c !e d E -!c !e !d !e \ No newline at end of file +!c !e !d !e +!z + +!z !x + +!z !x !y +!z !x y O \ No newline at end of file diff --git a/tests/move.result7 b/tests/move.result9 similarity index 90% copy from tests/move.result7 copy to tests/move.result9 index 4c0d9f64..3706e180 100644 --- a/tests/move.result7 +++ b/tests/move.result9 @@ -29,4 +29,8 @@ target-loop-b O !c !e + !c !e !d + !c !e d E -!c !e !d !e \ No newline at end of file +!c !e !d !e +!z + +!z !x +!z !y +!z y O \ No newline at end of file diff --git a/tests/move.test b/tests/move.test index 7cf91d3e..f59174c5 100755 --- a/tests/move.test +++ b/tests/move.test @@ -73,4 +73,18 @@ echo -ne 'LIST --all --with-target' | pwmc $PWMC_ARGS move > result cmp move.result7 result rm -f result +echo +echo "Test 8. Move child whos target value is a parent." +echo -ne 'MOVE !x z' | pwmc $PWMC_ARGS -S move +echo -ne 'LIST --all --with-target' | pwmc $PWMC_ARGS move > result +cmp move.result8 result +rm -f result + +echo +echo "Test 9. Move child whos target value is a parent." +echo -ne 'MOVE z\tx\t!y z' | pwmc $PWMC_ARGS -S move +echo -ne 'LIST --all --with-target' | pwmc $PWMC_ARGS move > result +cmp move.result9 result +rm -f result + test_success diff --git a/tests/rename.result3 b/tests/rename.result3 index c116b91e..883099b9 100644 --- a/tests/rename.result3 +++ b/tests/rename.result3 @@ -13,4 +13,8 @@ target-loop-b O !c !d !e !c !e !d + -!d !e \ No newline at end of file +!d !e +!x + +!x !y +!x y T !z +!z \ No newline at end of file diff --git a/tests/rename.result4 b/tests/rename.result4 index 50b0a6a1..665665cc 100644 --- a/tests/rename.result4 +++ b/tests/rename.result4 @@ -13,4 +13,8 @@ target-loop-b O !c !d !e !c !e !d + -!d !e \ No newline at end of file +!d !e +!x + +!x !y +!x y T !z +!z \ No newline at end of file diff --git a/tests/xpath.result4 b/tests/xpath.result4 index 1d52282f..e9381c02 100644 --- a/tests/xpath.result4 +++ b/tests/xpath.result4 @@ -14,4 +14,8 @@ target-loop-b O !c !d !e !c !e !d + -!d !e \ No newline at end of file +!d !e +!x + +!x !y +!x y T !z +!z \ No newline at end of file -- 2.11.4.GIT