summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2019-02-20 17:25:22 +0100
committerDaniel Vetter <daniel.vetter@ffwll.ch>2019-02-22 16:17:38 +0100
commit00075e67670347f77a7f96b6f56531e35bbc5994 (patch)
tree0046df8a77f6f027cd397e4f2b871cd6f69f8468 /tests
parent2b7dd10a4e2ea0cabff68421fd15e96c99be3cad (diff)
tests/kms_lease: Add invalid planes tests
Test gap because we're using universal planes by default. Fix that. Cc: Keith Packard <keithp@keithp.com> Reviewed-by: Lyude Paul <lyude@redhat.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'tests')
-rw-r--r--tests/kms_lease.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/kms_lease.c b/tests/kms_lease.c
index cca42459..70a96362 100644
--- a/tests/kms_lease.c
+++ b/tests/kms_lease.c
@@ -573,6 +573,20 @@ static void lease_invalid_crtc(data_t *data)
igt_assert_eq(ret, -EINVAL);
}
+static void lease_invalid_plane(data_t *data)
+{
+ lease_t lease;
+ uint32_t save_plane_id;
+ int ret;
+
+ /* Create an invalid lease */
+ save_plane_id = data->plane_id;
+ data->plane_id = 0xbaadf00d;
+ ret = make_lease(data, &lease);
+ data->plane_id = save_plane_id;
+ igt_assert_eq(ret, -EINVAL);
+}
+
static void run_test(data_t *data, void (*testfunc)(data_t *))
{
@@ -625,6 +639,7 @@ igt_main
{ "lease_again", lease_again },
{ "lease_invalid_connector", lease_invalid_connector },
{ "lease_invalid_crtc", lease_invalid_crtc },
+ { "lease_invalid_plane", lease_invalid_plane },
{ }
}, *f;