diff mbox series

[OSSTEST,6/8] cri-getplatforms: Honour new MF_SIMULATE_PLATFORMS env var

Message ID 20201001162439.18160-6-iwj@xenproject.org (mailing list archive)
State New, archived
Headers show
Series [OSSTEST,1/8] Executive: Fix an undef warning message | expand

Commit Message

Ian Jackson Oct. 1, 2020, 4:24 p.m. UTC
This is to be expanded by the shell, using eval, so that it can refer
to $xenarch, $suite and $blessing.

No functional change if this variable is unset, or empty.  If it is
set to a single space, cri-getplatforms produces no output (as it does
anyway in standalone mode).

Signed-off-by: Ian Jackson <iwj@xenproject.org>
---
 cri-getplatforms | 4 ++++
 1 file changed, 4 insertions(+)
diff mbox series

Patch

diff --git a/cri-getplatforms b/cri-getplatforms
index 1f206908..9f4cae56 100755
--- a/cri-getplatforms
+++ b/cri-getplatforms
@@ -19,6 +19,10 @@ 
 getplatforms () {
 	local xenarch=$1
 	local suite=$2
+	if [ "x$MF_SIMULATE_PLATFORMS" != x ]; then
+		eval "echo $MF_SIMULATE_PLATFORMS"
+		return
+	fi
         perl -e '
                 use Osstest;
                 csreadconfig();