#!/usr/bin/env bash
set -euo pipefail
# shellcheck source-path=SCRIPTDIR
source "$(dirname "$0")/assert.sh"

export PATH="/XSTARTX:$MISE_DATA_DIR/shims:/XENDX:$PATH"
mise i node
mise reshim
assert "node -v" "v20.0.0"

# should still have this prefix since mise should only modify PATH
# starting at the shim directory
assert_matches "node -p 'process.env.PATH'" "^/XSTARTX:"
