1
0
mirror of https://github.com/ipfs/kubo.git synced 2025-07-28 06:34:05 +08:00

add a failing test case for calling dht put with a bad key

see 

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
This commit is contained in:
Steven Allen
2018-06-13 17:59:38 -07:00
parent 6112150d04
commit 384e2c40b2

@ -41,7 +41,15 @@ test_expect_success 'get with good keys' '
ipfsi 1 dht get "/ipns/$PEERID_2" | grep -aq "/ipfs/$HASH"
'
test_expect_failure 'put with bad keys (issue #4611)' '
test_expect_failure 'put with bad keys fails (issue #5113)' '
ipfsi 0 dht put "foo" "bar" >putted
ipfsi 0 dht put "/pk/foo" "bar" >>putted
ipfsi 0 dht put "/ipns/foo" "bar" >>putted
[ ! -s putted ] ||
test_fsh cat putted
'
test_expect_failure 'put with bad keys returns error (issue #4611)' '
! ipfsi 0 dht put "foo" "bar" &&
! ipfsi 0 dht put "/pk/foo" "bar" &&
! ipfsi 0 dht put "/ipns/foo" "bar"