Enhancment/fixes to subrun capability:

I tried to enable subrun tests as an items-based test. The idea was to defined a single test "optx" that would be an items based test whose items were the subrun targets.

I used the following testconfig definition:

[subrun]

runwait yes

target #{getenv TEST_TARGET}

run-name #{getenv MT_RUNNAME}


[items]

TEST_TARGET [system


The compose_targets.csh script just uses the master target name (MT_TARGET), removes the -optall extension, and then uses the list of opt# defined in the variable MASTER_OPTS to define new targets
Essentially: MT_TARGET-opt# (where MT_TARGET has been stripped of the -optall extension)

The initial trial appears to have worked, partially, in invoking runs.
However, when attempting to remove the master target run, I get errors during cleanup related to:

INFO: (0) Running sub megatest command: megatest -log -runname NO-RUNNAME -target <path>/subrun-opt3 -start-dir -remove-runs


The system seems to lose track of the subrun RUNNAME and TESTPATT, and the end result is I cannot clear the master target run from dashboard.

as in "make clean TARGET=<master_target> RUNNAME=<runname>" will not clean the run due to the above failures.


I would like to enable the [subrun] feature in combination with [items] (or [itemstable]) which seems like a natural extension of existing megatest functionality