-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix offline full path resolution bug
- Loading branch information
1 parent
5853eac
commit 60ac591
Showing
2 changed files
with
37 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#!/bin/sh | ||
# | ||
# Copyright (c) 2014 Jeromy Johnson | ||
# MIT Licensed; see the LICENSE file in this repository. | ||
# | ||
|
||
test_description="Test add and cat commands" | ||
|
||
. lib/test-lib.sh | ||
|
||
test_init_ipfs | ||
|
||
test_expect_success "ipfs add file succeeds" ' | ||
echo "some content" > afile && | ||
HASH=$(ipfs add -q afile) | ||
' | ||
|
||
test_expect_success "ipfs cat file suceeds" ' | ||
ipfs cat $HASH > out_1 | ||
' | ||
|
||
test_expect_success "output looks good" ' | ||
test_cmp afile out_1 | ||
' | ||
|
||
test_expect_success "ipfs cat /ipfs/file succeeds" ' | ||
ipfs cat /ipfs/$HASH > out_2 | ||
' | ||
|
||
test_expect_success "output looks good" ' | ||
test_cmp afile out_2 | ||
' | ||
|
||
test_done |