From 439840ace6fd56b02fc1121a1b67d7673d6eab41 Mon Sep 17 00:00:00 2001 From: David Allsopp Date: Mon, 10 Jun 2024 12:26:57 +0100 Subject: [PATCH] Test update --- tests/reftests/env.win32.test | 41 +++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/tests/reftests/env.win32.test b/tests/reftests/env.win32.test index 7dee3d007b9..3169a7dd01c 100644 --- a/tests/reftests/env.win32.test +++ b/tests/reftests/env.win32.test @@ -1,4 +1,45 @@ N0REP0 +### : root and switches with spaces : +### +opam-version: "2.0" +flags: compiler +### RT="$BASEDIR/root 2" +### SW="switch w spaces" +### OPAMNOENVNOTICE=0 +### opam init -na --bare --bypass-check --disable-sandbox --root "$RT" defaut ./REPO +No configuration file found, using built-in defaults. + +<><> opam root file store <><><><><><><><><><><><><><><><><><><><><><><><><><><> + +You have specified a root directory for opam containing a space. + +Many parts of the OCaml ecosystem do not presently work correctly +when installed to directories containing spaces. You have been warned! + +Where should opam store files? + 1. Redirect files to a directory in C:\opamroot + 2. Redirect files to an alternate directory +> 3. Do not redirect anything and stick with ${BASEDIR}/root 2 + 4. Abort initialisation + +[1/2/3/4] 3 + +<><> Fetching repository information ><><><><><><><><><><><><><><><><><><><><><> +[defaut] Initialised +### opam switch create "./$SW" nv --root "$RT" + +<><> Installing new switch packages <><><><><><><><><><><><><><><><><><><><><><> +Switch invariant: ["nv"] + +<><> Processing actions <><><><><><><><><><><><><><><><><><><><><><><><><><><><> +-> installed nv.1 +Done. +# Run eval $(opam env '--root=${BASEDIR}/root 2' '--switch=${BASEDIR}/switch w spaces') to update the current shell environment +### opam env --root "$RT" --switch "./$SW" | grep "PREFIX" | ';' -> ':' +OPAM_SWITCH_PREFIX='${BASEDIR}/switch w spaces\_opam': export OPAM_SWITCH_PREFIX: +### opam var root --root "$RT" +${BASEDIR}/root 2 +### OPAMNOENVNOTICE=1 ### : setenv & build env rewriting : ### opam switch create rewriting --empty ### : Test for #4861