diff --git a/test/meson.build b/test/meson.build index 1aef05c..aca43c7 100644 --- a/test/meson.build +++ b/test/meson.build @@ -44,6 +44,7 @@ tests = { 'composition-3x-fail', 'composition-3x-partial', 'composition-3x-force', + 'zpos-2x-reverse', ], 'dynamic': [ 'same', diff --git a/test/test_alloc.c b/test/test_alloc.c index f1571ce..be277cf 100644 --- a/test/test_alloc.c +++ b/test/test_alloc.c @@ -464,6 +464,26 @@ static struct test_case tests[] = { }, }, }, + { + .name = "zpos-2x-reverse", + /* Layer on top comes first */ + .layers = { + { + .width = 100, + .height = 100, + .zpos = 2, + .compat = { PRIMARY_PLANE, OVERLAY_PLANE }, + .result = OVERLAY_PLANE, + }, + { + .width = 1920, + .height = 1080, + .zpos = 1, + .compat = { PRIMARY_PLANE, OVERLAY_PLANE }, + .result = PRIMARY_PLANE, + }, + }, + }, { .name = "composition-3x", .layers = {