From 3ba6fc1a4770689736d519ee0b7123912be32d3f Mon Sep 17 00:00:00 2001 From: Albert Chu Date: Tue, 15 Aug 2017 08:56:16 -0700 Subject: [PATCH] t/kvs: Add more tests to t1002-kvs-extra Add additional bad treeobj test cases. --- t/t1002-kvs-extra.t | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/t/t1002-kvs-extra.t b/t/t1002-kvs-extra.t index d690ba90a1e5..f322b24dc50c 100755 --- a/t/t1002-kvs-extra.t +++ b/t/t1002-kvs-extra.t @@ -222,7 +222,8 @@ test_expect_success 'kvs: put-treeobj: fails bad dirent: bad link data' ' test_expect_success 'kvs: put-treeobj: fails bad dirent: bad ref data' ' flux kvs unlink -Rf $TEST && - test_must_fail ${KVSBASIC} put-treeobj $TEST.a="{\"data\":42,\"type\":\"dirref\",\"ver\":1}" + test_must_fail ${KVSBASIC} put-treeobj $TEST.a="{\"data\":42,\"type\":\"dirref\",\"ver\":1}" && + test_must_fail ${KVSBASIC} put-treeobj $TEST.a="{\"data\":"sha1-4087718d190b373fb490b27873f61552d7f29dbe",\"type\":\"dirref\",\"ver\":1}" ' test_expect_success 'kvs: put-treeobj: fails bad dirent: bad blobref' ' @@ -237,6 +238,7 @@ test_expect_success 'kvs: getat: fails bad on dirent' ' test_must_fail ${KVSBASIC} getat "{\"data\":[\"sha1-aaa\"],\"type\":\"dirref\",\"ver\":1}" $TEST.a && test_must_fail ${KVSBASIC} getat "{\"data\":[\"sha1-bbb\"],\"type\":\"dirref\",\"ver\":1}" $TEST.a && test_must_fail ${KVSBASIC} getat "{\"data\":42,\"type\":\"dirref\",\"ver\":1}" $TEST.a + test_must_fail ${KVSBASIC} getat "{\"data\":"sha1-4087718d190b373fb490b27873f61552d7f29dbe",\"type\":\"dirref\",\"ver\":1}" $TEST.a ' test_expect_success 'kvs: getat: works on root from get-treeobj' '