http://bugzilla.suse.com/show_bug.cgi?id=1087867
Bug ID: 1087867
Summary: yast2 testsuite runs commands from the real system and
asks for the root password in popup
Classification: openSUSE
Product: openSUSE Distribution
Version: Leap 15.0
Hardware: Other
OS: Other
Status: NEW
Severity: Normal
Priority: P5 - None
Component: YaST2
Assignee: yast2-maintainers@suse.de
Reporter: lslezak@suse.com
QA Contact: jsrain@suse.com
Found By: ---
Blocker: ---
Created attachment 765751
--> http://bugzilla.suse.com/attachment.cgi?id=765751&action=edit
terminal screenshot (sorry for using the Czech language, setting $LC_ALL or
$LANGUAGE did not help, I'd have to restart the desktop session completely...)
See the screenshot.
Environment:
- Running firewalld is required ("systemctl start firewalld")
- Reproduced in the KDE desktop (the popup probably depends on used desktop)
How to reproduce:
- Run "rake test:unit" in the yast2 sources
- The popup is displayed several times during the testsuite, it seems some
"read" mocking is missing completely.
Workaround:
- Stop the firewalld service ("systemctl stop firewalld"), then the popup is
not displayed
Full backtrace (added debugger call in the code):
[105, 114] in
/local/lslezak/GIT/yast/yast2/library/network/src/lib/y2firewall/firewalld/api.rb
105:
106: # @return [Boolean] The firewalld service state (exit code)
107: def state
108: require "byebug"
109: byebug
=> 110: case Yast::Execute.on_target("firewallctl", "state",
allowed_exitstatus: [0, 252])
111: when 0
112: "running"
113: when 252
114: "not running"
(byebug) bt
--> #0 Y2Firewall::Firewalld::Api.state at
/local/lslezak/GIT/yast/yast2/library/network/src/lib/y2firewall/firewalld/api.rb:110
#1 Y2Firewall::Firewalld::Api.running? at
/local/lslezak/GIT/yast/yast2/library/network/src/lib/y2firewall/firewalld/api.rb:95
#2 Y2Firewall::Firewalld::Api.initialize(mode#NilClass,
permanent#TrueClass) at
/local/lslezak/GIT/yast/yast2/library/network/src/lib/y2firewall/firewalld/api.rb:63
ͱ-- #3 Class.new(*args) at
/local/lslezak/GIT/yast/yast2/library/network/src/lib/network/susefirewalld.rb:75
#4 Yast::SuSEFirewalldClass.initialize at
/local/lslezak/GIT/yast/yast2/library/network/src/lib/network/susefirewalld.rb:75
ͱ-- #5 Class.new(*args) at
/local/lslezak/GIT/yast/yast2/library/network/src/modules/SuSEFirewall.rb:34
#6