2 # vim:ts=4:sw=4:expandtab
4 # Regression test for inplace restarting with dock clients
8 my $tmp = fresh_workspace;
10 #####################################################################
11 # verify that there is no dock window yet
12 #####################################################################
14 # Children of all dockareas
15 my @docked = get_dock_clients;
17 is(@docked, 0, 'no dock clients yet');
21 my $window = open_window({
22 background_color => '#FF0000',
23 window_type => $x->atom(name => '_NET_WM_WINDOW_TYPE_DOCK'),
26 #####################################################################
27 # check that we can find it in the layout tree at the expected position
28 #####################################################################
30 @docked = get_dock_clients;
31 is(@docked, 1, 'one dock client found');
34 my $docknode = $docked[0];
36 is($docknode->{rect}->{height}, 30, 'dock node has unchanged height');
38 # perform an inplace-restart
44 #####################################################################
45 # check that we can still find the dock client
46 #####################################################################
48 @docked = get_dock_clients;
49 is(@docked, 1, 'one dock client found');
50 $docknode = $docked[0];
52 is($docknode->{rect}->{height}, 30, 'dock node has unchanged height after restart');
56 wait_for_unmap $window;
58 @docked = get_dock_clients;
59 is(@docked, 0, 'no dock clients found');
61 #####################################################################
62 # create a dock client with a 1px border
63 #####################################################################
65 $window = open_window({
67 rect => [ 0, 0, 30, 20 ],
68 background_color => '#00FF00',
69 window_type => $x->atom(name => '_NET_WM_WINDOW_TYPE_DOCK'),
72 @docked = get_dock_clients;
73 is(@docked, 1, 'one dock client found');
74 $docknode = $docked[0];
76 is($docknode->{rect}->{height}, 20, 'dock node has unchanged height');
80 @docked = get_dock_clients;
81 is(@docked, 1, 'one dock client found');
82 $docknode = $docked[0];
84 is($docknode->{rect}->{height}, 20, 'dock node has unchanged height');