mirror of
https://github.com/vbatts/go-mtree.git
synced 2024-11-22 00:15:39 +00:00
cli.test: add case from #90
Closes #90 Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
This commit is contained in:
parent
efe17f56ae
commit
e2640e6dfa
1 changed files with 18 additions and 0 deletions
18
test/cli/0007.sh
Normal file
18
test/cli/0007.sh
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
#!/bin/bash
|
||||||
|
set -e
|
||||||
|
|
||||||
|
name=$(basename $0)
|
||||||
|
root="$(dirname $(dirname $(dirname $0)))"
|
||||||
|
gomtree=$(readlink -f ${root}/gomtree)
|
||||||
|
left=$(mktemp -d /tmp/go-mtree.XXXXXX)
|
||||||
|
right=$(mktemp -d /tmp/go-mtree.XXXXXX)
|
||||||
|
|
||||||
|
echo "[${name}] Running in ${left} and ${right}"
|
||||||
|
|
||||||
|
touch ${left}/one
|
||||||
|
touch ${left}/two
|
||||||
|
cp -a ${left}/one ${right}/
|
||||||
|
|
||||||
|
$gomtree -K "sha256digest" -p ${left} -c > /tmp/left.mtree
|
||||||
|
$gomtree -k "sha256digest" -p ${right} -f /tmp/left.mtree
|
||||||
|
rm -fr ${left} ${right}
|
Loading…
Reference in a new issue