2009-08-05 21:37:11 +02:00
|
|
|
#!perl
|
|
|
|
# vim:ts=4:sw=4:expandtab
|
|
|
|
|
2011-03-09 20:25:17 +01:00
|
|
|
use i3test;
|
2009-08-05 21:37:11 +02:00
|
|
|
|
2009-10-26 20:04:37 +01:00
|
|
|
my $x = X11::XCB::Connection->new;
|
2009-08-05 21:37:11 +02:00
|
|
|
|
2011-03-09 20:25:17 +01:00
|
|
|
fresh_workspace;
|
2009-08-05 21:37:11 +02:00
|
|
|
|
|
|
|
#####################################################################
|
|
|
|
# Ensure IPC works by switching workspaces
|
|
|
|
#####################################################################
|
|
|
|
|
|
|
|
# Create a window so we can get a focus different from NULL
|
2011-03-09 20:25:17 +01:00
|
|
|
my $window = open_standard_window($x);
|
2011-09-23 21:37:45 +02:00
|
|
|
sync_with_i3($x);
|
2009-08-05 21:37:11 +02:00
|
|
|
|
2009-10-26 20:04:37 +01:00
|
|
|
my $focus = $x->input_focus;
|
2009-08-05 21:37:11 +02:00
|
|
|
|
2011-03-09 20:25:17 +01:00
|
|
|
# Switch to another workspace
|
|
|
|
fresh_workspace;
|
2009-08-05 21:37:11 +02:00
|
|
|
|
2011-09-23 21:37:45 +02:00
|
|
|
sync_with_i3($x);
|
2009-10-26 20:04:37 +01:00
|
|
|
my $new_focus = $x->input_focus;
|
2009-08-05 21:37:11 +02:00
|
|
|
isnt($focus, $new_focus, "Focus changed");
|
|
|
|
|
2011-03-09 20:25:17 +01:00
|
|
|
done_testing;
|