diff --git a/testcases/lib/i3test.pm b/testcases/lib/i3test.pm index 12f81ea1..d6d71b23 100644 --- a/testcases/lib/i3test.pm +++ b/testcases/lib/i3test.pm @@ -529,10 +529,19 @@ sub get_ws_content { Returns the container ID of the currently focused container on C<$workspace>. +Note that the container ID is B the X11 window ID, so comparing the result +of C with a window's C<< ->{id} >> property does B work. + my $ws = fresh_workspace; my $first_window = open_window; + my $first_id = get_focused(); + my $second_window = open_window; - is(get_focused($ws), $second_window, 'second window focused'); + my $second_id = get_focused(); + + cmd 'focus left'; + + is(get_focused($ws), $first_id, 'second window focused'); =cut sub get_focused {