Implement focus command (and extend t/21-next-prev.t to test it)

This commit is contained in:
Michael Stapelberg
2010-06-01 18:49:43 +02:00
parent 67a6bd5589
commit a25dc3e988
2 changed files with 22 additions and 1 deletions

View File

@ -3,7 +3,7 @@
#
# Tests focus switching (next/prev)
#
use i3test tests => 13;
use i3test tests => 14;
use X11::XCB qw(:all);
use v5.10;
@ -81,4 +81,11 @@ $i3->command('next horizontal')->recv;
($nodes, $focus) = get_ws_content($tmp);
is($focus->[0], $right, 'right container focused');
# Test focus command
$i3->command(qq|[con_id="$mid"] focus|)->recv;
($nodes, $focus) = get_ws_content($tmp);
is($focus->[0], $mid, 'middle container focused');
diag( "Testing i3, Perl $], $^X" );