DEBUG=1 bundle exec rspec spec/libyui_client_spec.rb:8 Run options: include {:locations=>{"./spec/libyui_client_spec.rb"=>[8]}} LibyuiClient Starting /usr/sbin/yast2 host... Waiting for localhost:14155... launches application '/usr/sbin/yast2 host' Query: http://localhost:14155/widgets?id=wizard Response (404:Not Found): { "error" : "No dialog is open" } Query: http://localhost:14155/widgets?id=wizard Response (200:OK): [ { "class" : "YWizard", "debug_label" : "Host Configuration", "hstretch" : true, "id" : "wizard", "vstretch" : true } ] displays 'Host Configuration' Wizard Query: http://localhost:14155/widgets?id=add Response (200:OK): [ { "class" : "YPushButton", "debug_label" : "Add", "fkey" : 3, "id" : "add", "label" : "Ad&d" } ] Query: http://localhost:14155/widgets?action=press&id=add Response (200:OK): clicks 'Add' Button Query: http://localhost:14155/widgets?type=YDialog Response (200:OK): [ { "class" : "YDialog", "hstretch" : true, "type" : "popup" } ] displays 'popup' Dialog Query: http://localhost:14155/widgets?id=host Response (200:OK): [ { "class" : "YInputField", "debug_label" : "IP Address", "hstretch" : true, "id" : "host", "label" : "&IP Address", "password_mode" : false, "valid_chars" : "0123456789abcdefABCDEF.:", "value" : "" } ] Query: http://localhost:14155/widgets?action=enter_text&id=host&value=192.168.3.3 Response (200:OK): types '192.168.3.3' on 'IP Address' TextBox Query: http://localhost:14155/widgets?id=host Response (200:OK): [ { "class" : "YInputField", "debug_label" : "IP Address", "hstretch" : true, "id" : "host", "label" : "&IP Address", "password_mode" : false, "valid_chars" : "0123456789abcdefABCDEF.:", "value" : "192.168.3.3" } ] Query: http://localhost:14155/widgets?id=name Response (200:OK): [ { "class" : "YInputField", "debug_label" : "Hostname", "hstretch" : true, "id" : "name", "label" : "&Hostname", "password_mode" : false, "value" : "" } ] Query: http://localhost:14155/widgets?action=enter_text&id=name&value=awesome.hostname Response (200:OK): types 'awesome.hostname' on 'Hostname' TextBox Query: http://localhost:14155/widgets?id=name Response (200:OK): [ { "class" : "YInputField", "debug_label" : "Hostname", "hstretch" : true, "id" : "name", "label" : "&Hostname", "password_mode" : false, "value" : "awesome.hostname" } ] Query: http://localhost:14155/widgets?id=aliases Response (200:OK): [ { "class" : "YInputField", "debug_label" : "Host Aliases", "hstretch" : true, "id" : "aliases", "label" : "Hos&t Aliases", "password_mode" : false, "value" : "" } ] Query: http://localhost:14155/widgets?action=enter_text&id=aliases&value=aliases.hostname Response (200:OK): types 'aliases.hostname' on 'Host Aliases' TextBox Query: http://localhost:14155/widgets?id=aliases Response (200:OK): [ { "class" : "YInputField", "debug_label" : "Host Aliases", "hstretch" : true, "id" : "aliases", "label" : "Hos&t Aliases", "password_mode" : false, "value" : "aliases.hostname" } ] Query: http://localhost:14155/widgets?id=ok Response (200:OK): [ { "class" : "YPushButton", "debug_label" : "OK", "fkey" : 10, "id" : "ok", "label" : "&OK" } ] Query: http://localhost:14155/widgets?action=press&id=ok Response (200:OK): clicks 'OK' Button Query: http://localhost:14155/widgets?id=table Response (200:OK): [ { "alignment" : [ "left", "left", "left" ], "class" : "YTable", "columns" : 3, "hasMultiSelection" : false, "header" : [ "IP Address", "Hostnames", "Host Aliases" ], "hstretch" : true, "icon_base_path" : "", "id" : "table", "immediate_mode" : false, "items" : [ { "labels" : [ "127.0.0.1", "localhost", "" ], "selected" : true }, { "labels" : [ "::1", "localhost", "ipv6-localhost ipv6-loopback" ] }, { "labels" : [ "fe00::0", "ipv6-localnet", "" ] }, { "labels" : [ "ff00::0", "ipv6-mcastprefix", "" ] }, { "labels" : [ "ff02::1", "ipv6-allnodes", "" ] }, { "labels" : [ "ff02::2", "ipv6-allrouters", "" ] }, { "labels" : [ "ff02::3", "ipv6-allhosts", "" ] }, { "labels" : [ "192.168.3.3", "awesome.hostname", "aliases.hostname" ] }, { "labels" : [ "192.168.3.3", "awesome.hostname", "aliases.hostname" ] } ], "items_count" : 9, "keep_sorting" : false, "notify" : true, "vstretch" : true } ] Query: http://localhost:14155/widgets?action=select_table&id=table&value=192.168.3.3 Response (200:OK): selects row column '192.168.3.3' in table 'table' Query: http://localhost:14155/widgets?id=next Response (200:OK): [ { "class" : "YQWizardButton", "debug_label" : "OK", "fkey" : 10, "id" : "next", "label" : "&OK" } ] Query: http://localhost:14155/widgets?action=press&id=next Response (200:OK): clicks 'OK' Button writes IP Address, Hostname and Host Aliases to /etc/hosts Finished in 2.12 seconds (files took 0.18078 seconds to load) 1 example, 0 failures