master
sh 23 lines 703 Bytes
Raw
1 #!/usr/bin/env bash
2
3 test_description="Test non-standard datastores"
4
5 . lib/test-lib.sh
6
7 profiles=("flatfs" "pebbleds" "badgerds")
8 proot="$(mktemp -d "${TMPDIR:-/tmp}/t0025.XXXXXX")"
9
10 for profile in "${profiles[@]}"; do
11 test_expect_success "'ipfs init --empty-repo=false --profile=$profile' succeeds" '
12 BITS="2048" &&
13 IPFS_PATH="$proot/$profile" &&
14 ipfs init --empty-repo=false --profile=$profile
15 '
16 test_expect_success "'ipfs pin add' and 'pin ls' works with $profile" '
17 export IPFS_PATH="$proot/$profile" &&
18 echo -n "hello_$profile" | ipfs block put --pin=true > hello_cid &&
19 ipfs pin ls -t recursive "$(cat hello_cid)"
20 '
21 done
22
23 test_done