From fb34688841668e6e4c939395c8387feabe8ddfdf Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Mon, 30 Nov 2020 22:42:40 +0300 Subject: Add support for config.test.runner --- libbuild2/test/script/script.hxx | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'libbuild2/test/script/script.hxx') diff --git a/libbuild2/test/script/script.hxx b/libbuild2/test/script/script.hxx index 2789cab..d387a11 100644 --- a/libbuild2/test/script/script.hxx +++ b/libbuild2/test/script/script.hxx @@ -28,6 +28,8 @@ namespace build2 using build2::script::redirect_type; using build2::script::line_type; using build2::script::command_expr; + using build2::script::expr_term; + using build2::script::command; using build2::script::deadline; using build2::script::timeout; @@ -105,6 +107,15 @@ namespace build2 virtual void create_temp_dir () override {assert (false);}; + // Return true if this is a test program path. + // + // Note that currently the test program is only specified via the test + // variable ($0 effectively). In the future we may invent some other + // means of marking a program as a test (builtin, etc). + // + bool + test_program (const path&); + // Variables. // public: @@ -163,6 +174,15 @@ namespace build2 location end_loc_; optional if_cond_; + + // Test program paths. + // + // Currently always contains a single element (see test_program() for + // details). While in the future there can be more of them, the zero + // index will always refer to the test variable value and can + // potentially be NULL (see reset_special() for details). + // + small_vector test_programs_; }; // group -- cgit v1.1