Skip to content

Automating DBuild & DTest

Michael Baas edited this page Oct 2, 2023 · 8 revisions

While the focus of this documentation is interactive used of DBuild/DTest in the Dyalog session, they can also be used in unattended mode (automated testing or build-processes with CI-Tools).

The easiest way to do that without any more tools is by launching Dyalog with the commandline-parameter "LX=⎕SE.UCMD'DBuild {myfile}.dyalogbuild". (DTest can be called in the same way!) NB: this will require a v18 unicode interpreter (or better).

Alternative solution

NB: This approach alsl works on classic interpreters.

A by-product of Dyalog's CITA-Project (Continous Integration Tool for APL) is the lx workspace which is primarily used within CITA. But we wanted to also support use cases like starting DBuild or DTest from the commandline.

In order to run a user command with Executor, follow these steps:

  1. download lx.dws
  2. commandline: dyalog lx RunUCMD="<Commandline>" CITA_Log="<NameOfLog>" [UDEBUG=ON]

The commandline arguments are:

  • RunUCMD=<Commandline> The name and arguments for the UCMD-Call (w/o leading ]), for example: RunUCMD="DBuild /git/MyPrj/MyPrj.dyalogbuild"
  • CITA_Log=<NameOfLog> Any output that is shown in the session will be collected into a logfile (using path & name you provided in <NameOfLog> with a .sessionlog.txt extension.
  • UDEBUG=ON If you set UDEBUG=ON, any errors will be shown in the session and APL will not ⎕OFF after running the command. However, as that defeats the purpose of automated testing, this will probably only be used in exotic circumstances (like the ones that triggered the addition of this modifier).

Clone this wiki locally