public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: gdb-patches@sourceware.org
Subject: [PATCH 2/3] sim: testsuite: skip tests when the port is disabled
Date: Sun,  4 Apr 2021 10:35:37 -0400	[thread overview]
Message-ID: <20210404143538.14995-2-vapier@gentoo.org> (raw)
In-Reply-To: <20210404143538.14995-1-vapier@gentoo.org>

If the port hasn't been enabled, don't try to run its tests.  Making
this dynamic simplifies the test harnesses and avoids duplicating a
bunch of target tuple checks.
---
 sim/testsuite/lib/sim-defs.exp | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/sim/testsuite/lib/sim-defs.exp b/sim/testsuite/lib/sim-defs.exp
index 1b40216ea6ed..e627b6efc595 100644
--- a/sim/testsuite/lib/sim-defs.exp
+++ b/sim/testsuite/lib/sim-defs.exp
@@ -205,6 +205,11 @@ proc run_sim_test { name requested_machs } {
     global global_cc_options
     global global_sim_options
 
+    if ![file exists [sim_tool_path]] {
+	unsupported "$name: missing simulator [sim_tool_path]"
+	return
+    }
+
     if [string match "*/*" $name] {
 	set file $name
 	set name [file tail $name]
-- 
2.30.2


  reply	other threads:[~2021-04-04 14:35 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-04 14:35 [PATCH 1/3] sim: testsuite: calculate $arch from $subdir Mike Frysinger
2021-04-04 14:35 ` Mike Frysinger [this message]
2021-04-04 14:35 ` [PATCH 3/3] sim: testsuite: support exit 77 for unsupported tests Mike Frysinger
2021-04-05 16:31 ` [PATCH 1/3] sim: testsuite: calculate $arch from $subdir Dimitar Dimitrov
2021-04-05 17:17   ` Mike Frysinger
2021-04-05 18:19     ` Dimitar Dimitrov
2021-05-06 20:51       ` Dimitar Dimitrov
2021-05-06 22:27         ` Mike Frysinger
2021-05-07 18:21         ` [PATCH/committed] sim: Add bfd include path for common testsuite tools Dimitar Dimitrov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210404143538.14995-2-vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --cc=gdb-patches@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).