mirror of
https://github.com/ipfs/kubo.git
synced 2025-07-01 10:49:24 +08:00
t0121, t0130, t0240: use iptb-lib.sh
License: MIT Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
This commit is contained in:
@ -17,19 +17,6 @@ test_expect_success "disable mdns" '
|
|||||||
|
|
||||||
test_launch_ipfs_daemon
|
test_launch_ipfs_daemon
|
||||||
|
|
||||||
export IPTB_ROOT="`pwd`/.iptb"
|
|
||||||
|
|
||||||
ipfsi() {
|
|
||||||
dir="$1"
|
|
||||||
shift
|
|
||||||
IPFS_PATH="$IPTB_ROOT/$dir" ipfs $@
|
|
||||||
}
|
|
||||||
|
|
||||||
check_has_connection() {
|
|
||||||
node=$1
|
|
||||||
ipfsi $node swarm peers | grep ipfs > /dev/null
|
|
||||||
}
|
|
||||||
|
|
||||||
test_expect_success "setup iptb nodes" '
|
test_expect_success "setup iptb nodes" '
|
||||||
iptb init -n 5 -f --bootstrap=none --port=0
|
iptb init -n 5 -f --bootstrap=none --port=0
|
||||||
'
|
'
|
||||||
|
@ -8,19 +8,6 @@ test_description="Test multiple ipfs nodes"
|
|||||||
|
|
||||||
. lib/test-lib.sh
|
. lib/test-lib.sh
|
||||||
|
|
||||||
export IPTB_ROOT="`pwd`/.iptb"
|
|
||||||
|
|
||||||
ipfsi() {
|
|
||||||
dir="$1"
|
|
||||||
shift
|
|
||||||
IPFS_PATH="$IPTB_ROOT/$dir" ipfs $@
|
|
||||||
}
|
|
||||||
|
|
||||||
check_has_connection() {
|
|
||||||
node=$1
|
|
||||||
ipfsi $node swarm peers | grep ipfs > /dev/null
|
|
||||||
}
|
|
||||||
|
|
||||||
startup_cluster() {
|
startup_cluster() {
|
||||||
test_expect_success "start up nodes" '
|
test_expect_success "start up nodes" '
|
||||||
iptb start
|
iptb start
|
||||||
|
@ -8,15 +8,8 @@ test_description="Test ipfs repo operations"
|
|||||||
|
|
||||||
. lib/test-lib.sh
|
. lib/test-lib.sh
|
||||||
|
|
||||||
export IPTB_ROOT="`pwd`/.iptb"
|
|
||||||
export DEBUG=true
|
export DEBUG=true
|
||||||
|
|
||||||
ipfsi() {
|
|
||||||
dir="$1"
|
|
||||||
shift
|
|
||||||
IPFS_PATH="$IPTB_ROOT/$dir" ipfs "$@"
|
|
||||||
}
|
|
||||||
|
|
||||||
setup_iptb() {
|
setup_iptb() {
|
||||||
test_expect_success "iptb init" '
|
test_expect_success "iptb init" '
|
||||||
iptb init -n4 --bootstrap none --port 0
|
iptb init -n4 --bootstrap none --port 0
|
||||||
|
Reference in New Issue
Block a user