1
0
mirror of https://github.com/tw93/Mole.git synced 2026-02-04 15:04:42 +00:00

test: fix empty directory cleanup depth and remove obsolete spinner test

This commit is contained in:
Tw93
2026-01-03 13:37:53 +08:00
parent a57cd22abf
commit 5ee7d2d703
2 changed files with 3 additions and 13 deletions

View File

@@ -25,21 +25,11 @@ setup() {
mkdir -p "$HOME"
}
teardown() {
unset MO_SPINNER_CHARS || true
}
@test "mo_spinner_chars returns default sequence when unset" {
@test "mo_spinner_chars returns default sequence" {
result="$(HOME="$HOME" bash --noprofile --norc -c "source '$PROJECT_ROOT/lib/core/common.sh'; mo_spinner_chars")"
[ "$result" = "|/-\\" ]
}
@test "mo_spinner_chars respects MO_SPINNER_CHARS override" {
export MO_SPINNER_CHARS="abcd"
result="$(HOME="$HOME" MO_SPINNER_CHARS="$MO_SPINNER_CHARS" bash --noprofile --norc -c "source '$PROJECT_ROOT/lib/core/common.sh'; mo_spinner_chars")"
[ "$result" = "abcd" ]
}
@test "detect_architecture maps current CPU to friendly label" {
expected="Intel"
if [[ "$(uname -m)" == "arm64" ]]; then