diff --git a/src/tests/meson.build b/src/tests/meson.build index 23ad92d98..42420116d 100644 --- a/src/tests/meson.build +++ b/src/tests/meson.build @@ -736,6 +736,7 @@ stacking_tests = [ 'sloppy-focus', 'sloppy-focus-pointer-rest', 'sloppy-focus-auto-raise', + 'sticky', 'strut-monitor-changes' ] diff --git a/src/tests/stacking/sticky.metatest b/src/tests/stacking/sticky.metatest new file mode 100644 index 000000000..f5b6b3bd1 --- /dev/null +++ b/src/tests/stacking/sticky.metatest @@ -0,0 +1,48 @@ +num_workspaces 2 +activate_workspace 0 + +new_client w wayland +create w/1 +show w/1 +stick w/1 +create w/2 +set_parent w/2 1 +show w/2 +wait +assert_stacking_showing w/1 w/2 + +activate_workspace 1 +assert_stacking_showing w/1 w/2 + +unstick w/1 +assert_sticky w/1 false +assert_sticky w/2 false +wait + +activate_workspace 0 +dispatch +assert_stacking_showing + +quit_client w + +new_client x x11 + +create x/1 +show x/1 +stick x/1 +create x/2 +set_parent x/2 1 +show x/2 +wait +assert_stacking_showing x/1 x/2 + +activate_workspace 1 +assert_stacking_showing x/1 x/2 + +unstick x/1 + +activate_workspace 0 +dispatch +assert_stacking_showing + +quit_client x