[sheepdog] [PATCH v2 1/2] tests/functional: update 041 for a case of restoring to non-existing snapshot
Hitoshi Mitake
mitake.hitoshi at lab.ntt.co.jp
Mon Oct 28 08:09:40 CET 2013
dog must report an error in such a case.
Signed-off-by: Hitoshi Mitake <mitake.hitoshi at lab.ntt.co.jp>
---
v2: more descriptive error message
tests/functional/041 | 5 +++++
tests/functional/041.out | 3 +++
2 files changed, 8 insertions(+)
diff --git a/tests/functional/041 b/tests/functional/041
index 1f4cf7c..aad2f32 100755
--- a/tests/functional/041
+++ b/tests/functional/041
@@ -59,3 +59,8 @@ $DOG vdi read test | md5sum
for i in `seq 1 $($DOG vdi list | grep "^s " | wc -l)`; do
$DOG vdi read test -s $i | md5sum
done
+
+# restore to non-existence snapshot, this must be error
+$DOG vdi restore test -s non-existence-tag < $STORE/backup.2.3
+
+true
diff --git a/tests/functional/041.out b/tests/functional/041.out
index cc1b000..5866ace 100644
--- a/tests/functional/041.out
+++ b/tests/functional/041.out
@@ -58,3 +58,6 @@ d210baf5c55b42b5e0edf04a8535ad6d -
d210baf5c55b42b5e0edf04a8535ad6d -
d210baf5c55b42b5e0edf04a8535ad6d -
d210baf5c55b42b5e0edf04a8535ad6d -
+Cannot get VDI info for test 0 non-existence-tag: Failed to find requested tag
+Failed to open VDI test
+Snapshot ID 0 or tag non-existence-tag doesn't exist
--
1.7.10.4
More information about the sheepdog
mailing list