Remove deprecated X connection test (UAT)

This commit is contained in:
Thibault Jouan 2015-04-28 09:44:49 +00:00
parent 27448abfc6
commit 6a4a15e9db
3 changed files with 0 additions and 19 deletions

View File

@ -1,5 +0,0 @@
Feature: connection to X server
Scenario: connects to X server
When I start uhwm
Then it must connect to X display

View File

@ -36,11 +36,6 @@ When /^the window name changes to "([^"]+)"$/ do |name|
x_client.window_name = name x_client.window_name = name
end end
Then /^it must connect to X display$/ do
uhwm_wait_ready
expect(x_socket_check uhwm.pid).to be true
end
Then /^the(?:\s(\w+))? window must be mapped$/ do |ident| Then /^the(?:\s(\w+))? window must be mapped$/ do |ident|
timeout_until 'window not mapped after %d seconds' do timeout_until 'window not mapped after %d seconds' do
x_window_map_state(x_client(ident).window_id) == 'IsViewable' x_window_map_state(x_client(ident).window_id) == 'IsViewable'

View File

@ -89,15 +89,6 @@ expected `#{message}' (#{times}) not seen after #{e.timeout} seconds in:
fail "cannot simulate X key `#{k}'" unless system "xdotool key #{k}" fail "cannot simulate X key `#{k}'" unless system "xdotool key #{k}"
end end
def x_socket_check pid
case RbConfig::CONFIG['host_os']
when /linux/
`netstat -xp 2> /dev/null`.lines.grep /\s+#{pid}\/ruby/
else
`sockstat -u`.lines.grep /\s+ruby.+\s+#{pid}/
end.any?
end
def x_window_map_state window_id def x_window_map_state window_id
`xwininfo -id #{window_id}`[/Map State: (\w+)/, 1] `xwininfo -id #{window_id}`[/Map State: (\w+)/, 1]
end end