From 13eea737f96b0d89f7420843b1c78433b6ff2ecc Mon Sep 17 00:00:00 2001 From: Rudi Grinberg Date: Fri, 20 Apr 2018 17:32:37 +0700 Subject: [PATCH] Don't use getenv_opt in configurator test --- test/blackbox-tests/test-cases/configurator/config/run.ml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/blackbox-tests/test-cases/configurator/config/run.ml b/test/blackbox-tests/test-cases/configurator/config/run.ml index 41bc97f0..ec2da3d1 100644 --- a/test/blackbox-tests/test-cases/configurator/config/run.ml +++ b/test/blackbox-tests/test-cases/configurator/config/run.ml @@ -1,9 +1,9 @@ module Configurator = Configurator.V1 let () = - begin match Sys.getenv_opt "DUNE_CONFIGURATOR" with - | None -> failwith "DUNE_CONFIGURATOR is not passed" - | Some _ -> print_endline "DUNE_CONFIGURATOR is present" + begin match Sys.getenv "DUNE_CONFIGURATOR" with + | exception Not_found -> failwith "DUNE_CONFIGURATOR is not passed" + | _ -> print_endline "DUNE_CONFIGURATOR is present" end; Configurator.main ~name:"config" (fun t -> match Configurator.ocaml_config_var t "version" with