Add addl test
This commit is contained in:
@@ -61,5 +61,18 @@ testNoramlizeDirOfFile001() {
|
|||||||
assertEquals "$expected" "$out/tests/.."
|
assertEquals "$expected" "$out/tests/.."
|
||||||
}
|
}
|
||||||
|
|
||||||
|
testWfRoot() {
|
||||||
|
expected=$(normalize_dir_of_file "$DIR/../install.sh")
|
||||||
|
|
||||||
|
dir=$(mktemp -d --tmpdir would-reformat-testProjectRoot001.XXXXXX)
|
||||||
|
cd "$dir" || exit
|
||||||
|
git init >/dev/null 2>&1
|
||||||
|
"$DIR"/../install.sh 2>&2 >/dev/null
|
||||||
|
|
||||||
|
got=$(wf_root $(pwd))
|
||||||
|
|
||||||
|
assertEquals "$expected" "$got"
|
||||||
|
}
|
||||||
|
|
||||||
# shellcheck disable=SC1091
|
# shellcheck disable=SC1091
|
||||||
source shunit2
|
source shunit2
|
||||||
|
|||||||
Reference in New Issue
Block a user