kubo/test/t0030-mount.sh
Christian Couder f06b9ca126 Rename test_launch_ipfs_mount into test_launch_ipfs_daemon_and_mount
License: MIT
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
2014-11-20 20:11:03 +01:00

40 lines
767 B
Bash
Executable File

#!/bin/sh
#
# Copyright (c) 2014 Christian Couder
# MIT Licensed; see the LICENSE file in this repository.
#
test_description="Test mount command"
. lib/test-lib.sh
# if in travis CI, dont test mount (no fuse)
if ! test_have_prereq FUSE; then
skip_all='skipping mount tests, fuse not available'
test_done
fi
test_launch_ipfs_daemon_and_mount
test_kill_ipfs_daemon
test_expect_success "mount directories can be removed" '
rmdir ipfs ipns
'
test_launch_ipfs_daemon
test_expect_failure "'ipfs mount' fails when no mount dir (issue #341)" '
test_must_fail ipfs mount >actual
'
test_expect_failure "'ipfs mount' looks good when it fails (issue #341)" '
! grep "IPFS mounted at" actual &&
! grep "IPNS mounted at" actual
'
test_kill_ipfs_daemon
test_done