[igt-dev] [PATCH 1/2] tests/kms_invalid_mode : Convert tests to dynamic
Nidhi Gupta
nidhi1.gupta at intel.com
Fri May 20 01:12:25 UTC 2022
Modified kms_invalid_mode to include dynamic test cases
for better reporting of the results.
Signed-off-by: Nidhi Gupta <nidhi1.gupta at intel.com>
---
tests/kms_invalid_mode.c | 19 ++++++++++++++-----
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/tests/kms_invalid_mode.c b/tests/kms_invalid_mode.c
index bb92a94e..bb524037 100644
--- a/tests/kms_invalid_mode.c
+++ b/tests/kms_invalid_mode.c
@@ -296,8 +296,11 @@ static const struct {
static data_t data;
-igt_main
-{
+igt_main {
+
+igt_output_t *output;
+enum pipe pipe;
+
igt_fixture {
data.drm_fd = drm_open_driver_master(DRIVER_ANY);
@@ -312,9 +315,15 @@ igt_main
}
for (int i = 0; i < ARRAY_SIZE(subtests); i++) {
- igt_subtest(subtests[i].name) {
- data.adjust_mode = subtests[i].adjust_mode;
- test(&data);
+ igt_subtest_with_dynamic(subtests[i].name) {
+ for_each_pipe(&data.display, pipe) {
+ for_each_valid_output_on_pipe(&data.display, pipe, output) {
+ igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), output->name) {
+ data.adjust_mode = subtests[i].adjust_mode;
+ test(&data);
+ }
+ }
+ }
}
}
--
2.26.2
More information about the igt-dev
mailing list