From: Petri Latvala <petri.latvala@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: Petri Latvala <petri.latvala@intel.com>
Subject: [igt-dev] [PATCH i-g-t 3/4] runner_tests: Add new mockup test binary
Date: Tue, 14 Jan 2020 11:17:44 +0200 [thread overview]
Message-ID: <20200114091745.4555-3-petri.latvala@intel.com> (raw)
In-Reply-To: <20200114091745.4555-1-petri.latvala@intel.com>
'dynamic' is a new mockup test binary. It has one subtest with two
dynamic subtests, first of which will fail.
Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
---
runner/runner_tests.c | 4 ++--
runner/testdata/dynamic.c | 12 ++++++++++++
runner/testdata/meson.build | 1 +
3 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 runner/testdata/dynamic.c
diff --git a/runner/runner_tests.c b/runner/runner_tests.c
index 9bbc4252..a232aa2b 100644
--- a/runner/runner_tests.c
+++ b/runner/runner_tests.c
@@ -25,9 +25,9 @@ static const char testdatadir[] = TESTDATA_DIRECTORY;
* that test binaries without subtests should still be counted as one
* for this macro.
*/
-#define NUM_TESTDATA_SUBTESTS 5
+#define NUM_TESTDATA_SUBTESTS 6
/* The total number of test binaries in runner/testdata/ */
-#define NUM_TESTDATA_BINARIES 3
+#define NUM_TESTDATA_BINARIES 4
static void igt_assert_eqstr(const char *one, const char *two)
{
diff --git a/runner/testdata/dynamic.c b/runner/testdata/dynamic.c
new file mode 100644
index 00000000..8e5de7d9
--- /dev/null
+++ b/runner/testdata/dynamic.c
@@ -0,0 +1,12 @@
+#include "igt.h"
+
+igt_main
+{
+ igt_subtest_with_dynamic("dynamic-subtest") {
+ igt_dynamic("failing")
+ igt_assert(false);
+
+ igt_dynamic("passing")
+ ;
+ }
+}
diff --git a/runner/testdata/meson.build b/runner/testdata/meson.build
index 2456f82a..631ba5b9 100644
--- a/runner/testdata/meson.build
+++ b/runner/testdata/meson.build
@@ -2,6 +2,7 @@
testdata_progs = [ 'successtest',
'no-subtests',
'skippers',
+ 'dynamic',
]
testdata_executables = []
--
2.20.1
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
next prev parent reply other threads:[~2020-01-14 9:17 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-14 9:17 [igt-dev] [PATCH i-g-t 1/4] lib: Don't dump log buffer when dynamic subtest failure is inherited Petri Latvala
2020-01-14 9:17 ` [igt-dev] [PATCH i-g-t 2/4] runner_tests: Replace magic numbers with named constants Petri Latvala
2020-01-14 9:17 ` Petri Latvala [this message]
2020-01-14 9:17 ` [igt-dev] [PATCH i-g-t 4/4] runner_tests: Test that dynamic subtest failure is handled correctly Petri Latvala
2020-01-15 13:09 ` Arkadiusz Hiler
2020-01-16 11:47 ` Petri Latvala
2020-01-14 9:38 ` [igt-dev] ✗ GitLab.Pipeline: warning for series starting with [i-g-t,1/4] lib: Don't dump log buffer when dynamic subtest failure is inherited Patchwork
2020-01-14 10:12 ` [igt-dev] ✓ Fi.CI.BAT: success " Patchwork
2020-01-16 10:36 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
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=20200114091745.4555-3-petri.latvala@intel.com \
--to=petri.latvala@intel.com \
--cc=igt-dev@lists.freedesktop.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