From 7db42ab1b9d3c764772ca63c74bf44bb2b8b8325 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sat, 9 Jul 2022 14:35:38 -0400 Subject: First-class programs instead of having a "lux program" extension. --- stdlib/source/program/aedifex/command/test.lux | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'stdlib/source/program/aedifex/command/test.lux') diff --git a/stdlib/source/program/aedifex/command/test.lux b/stdlib/source/program/aedifex/command/test.lux index 7acc3e8c9..16a2694d4 100644 --- a/stdlib/source/program/aedifex/command/test.lux +++ b/stdlib/source/program/aedifex/command/test.lux @@ -17,7 +17,7 @@ [macro ["^" pattern]]] [world - ["[0]" program (.only Program)] + ["[0]" environment (.only Environment)] ["[0]" file] ["[0]" shell (.only Exit Shell)] ["[0]" console (.only Console)]]]] @@ -35,14 +35,14 @@ (def .public success "[TEST ENDED]") (def .public failure "[TEST FAILED]") -(def .public (do! console program fs shell resolution profile) - (-> (Console Async) (Program Async) (file.System Async) (Shell Async) Resolution (Command [Exit Any])) +(def .public (do! console environment fs shell resolution profile) + (-> (Console Async) (Environment Async) (file.System Async) (Shell Async) Resolution (Command [Exit Any])) (do async.monad - [environment (program.environment async.monad program) - .let [working_directory (at program directory)]] + [.let [home (at environment home) + working_directory (at environment directory)] + environment_vars (environment.environment async.monad environment)] (do [! ///action.monad] - [.let [home (at program home)] - [build_exit compiler program] (//build.do! console program fs shell resolution + [[build_exit compiler program] (//build.do! console environment fs shell resolution (has ///.#program (the ///.#test profile) profile))] (if (i.= shell.normal build_exit) (do ! @@ -63,7 +63,7 @@ [//build.#Python ///.#python] [//build.#Lua ///.#lua] [//build.#Ruby ///.#ruby]))] - process (at shell execute [(dictionary.composite environment command_environment) + process (at shell execute [(dictionary.composite environment_vars command_environment) working_directory test_command test_parameters]) -- cgit v1.2.3