Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package yast2-network for openSUSE:Factory checked in at 2021-07-04 22:10:35 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/yast2-network (Old) and /work/SRC/openSUSE:Factory/.yast2-network.new.2625 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-network" Sun Jul 4 22:10:35 2021 rev:458 rq:903626 version:4.4.20 Changes: -------- --- /work/SRC/openSUSE:Factory/yast2-network/yast2-network.changes 2021-06-19 23:02:04.147598466 +0200 +++ /work/SRC/openSUSE:Factory/.yast2-network.new.2625/yast2-network.changes 2021-07-04 22:10:39.397269089 +0200 @@ -1,0 +2,15 @@ +Thu Jul 1 08:47:20 UTC 2021 - Michal Filka <mfi...@suse.com> + +- bnc#1185936 + - do not crash with internal error when a sysctl file is + corrupted +- 4.4.20 + +------------------------------------------------------------------- +Fri Jun 25 08:07:09 UTC 2021 - Ancor Gonzalez Sosa <an...@suse.com> + +- Adapted to the new API of Y2Issues (related to jsc#PM-2620 and + bsc#1166743) +- 4.4.19 + +------------------------------------------------------------------- Old: ---- yast2-network-4.4.18.tar.bz2 New: ---- yast2-network-4.4.20.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2-network.spec ++++++ --- /var/tmp/diff_new_pack.WYQ3X7/_old 2021-07-04 22:10:39.905265160 +0200 +++ /var/tmp/diff_new_pack.WYQ3X7/_new 2021-07-04 22:10:39.909265129 +0200 @@ -17,7 +17,7 @@ Name: yast2-network -Version: 4.4.18 +Version: 4.4.20 Release: 0 Summary: YaST2 - Network Configuration License: GPL-2.0-only @@ -33,8 +33,8 @@ #for install task BuildRequires: yast2-storage-ng BuildRequires: rubygem(%rb_default_ruby_abi:yast-rake) -# Yast::Equatable -BuildRequires: yast2 >= 4.4.7 +# Updated API for Y2Issues +BuildRequires: yast2 >= 4.4.14 BuildRequires: yast2-packager >= 4.0.18 # Product control need xml agent @@ -49,8 +49,8 @@ Requires: sysconfig >= 0.80.0 Requires: yast2-proxy Requires: yast2-storage-ng -# Yast::Equatable -Requires: yast2 >= 4.4.7 +# Updated API for Y2Issues +Requires: yast2 >= 4.4.14 # Packages::vnc_packages Requires: augeas-lenses Requires: yast2-packager >= 4.0.18 ++++++ yast2-network-4.4.18.tar.bz2 -> yast2-network-4.4.20.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/README.md new/yast2-network-4.4.20/README.md --- old/yast2-network-4.4.18/README.md 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/README.md 2021-07-02 08:50:30.000000000 +0200 @@ -93,5 +93,5 @@ If you have any question, feel free to ask at the [development mailing list](http://lists.opensuse.org/yast-devel/) or at the -[#yast](https://webchat.freenode.net/?channels=%23yast) IRC channel on freenode. +[#yast](https://web.libera.chat/#yast) IRC channel on libera.chat. We'll do our best to provide a timely and accurate answer. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/package/yast2-network.changes new/yast2-network-4.4.20/package/yast2-network.changes --- old/yast2-network-4.4.18/package/yast2-network.changes 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/package/yast2-network.changes 2021-07-02 08:50:30.000000000 +0200 @@ -1,4 +1,19 @@ ------------------------------------------------------------------- +Thu Jul 1 08:47:20 UTC 2021 - Michal Filka <mfi...@suse.com> + +- bnc#1185936 + - do not crash with internal error when a sysctl file is + corrupted +- 4.4.20 + +------------------------------------------------------------------- +Fri Jun 25 08:07:09 UTC 2021 - Ancor Gonzalez Sosa <an...@suse.com> + +- Adapted to the new API of Y2Issues (related to jsc#PM-2620 and + bsc#1166743) +- 4.4.19 + +------------------------------------------------------------------- Thu Jun 17 16:20:44 UTC 2021 - Knut Anderssen <kanders...@suse.com> - Support 'boot' and 'on' as aliases for the 'auto' startmode diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/package/yast2-network.spec new/yast2-network-4.4.20/package/yast2-network.spec --- old/yast2-network-4.4.18/package/yast2-network.spec 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/package/yast2-network.spec 2021-07-02 08:50:30.000000000 +0200 @@ -17,7 +17,7 @@ Name: yast2-network -Version: 4.4.18 +Version: 4.4.20 Release: 0 Summary: YaST2 - Network Configuration License: GPL-2.0-only @@ -33,8 +33,8 @@ #for install task BuildRequires: rubygem(%rb_default_ruby_abi:yast-rake) BuildRequires: yast2-storage-ng -# Yast::Equatable -BuildRequires: yast2 >= 4.4.7 +# Updated API for Y2Issues +BuildRequires: yast2 >= 4.4.14 BuildRequires: yast2-packager >= 4.0.18 # Product control need xml agent @@ -49,8 +49,8 @@ Requires: sysconfig >= 0.80.0 Requires: yast2-proxy Requires: yast2-storage-ng -# Yast::Equatable -Requires: yast2 >= 4.4.7 +# Updated API for Y2Issues +Requires: yast2 >= 4.4.14 # Packages::vnc_packages Requires: yast2-packager >= 4.0.18 Requires: rubygem(%rb_default_ruby_abi:cfa) >= 0.6.4 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/lib/y2network/autoinst/config_reader.rb new/yast2-network-4.4.20/src/lib/y2network/autoinst/config_reader.rb --- old/yast2-network-4.4.18/src/lib/y2network/autoinst/config_reader.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/src/lib/y2network/autoinst/config_reader.rb 2021-07-02 08:50:30.000000000 +0200 @@ -1,4 +1,4 @@ -# Copyright (c) [2019] SUSE LLC +# Copyright c) [2019] SUSE LLC # # All Rights Reserved. # @@ -27,7 +27,7 @@ require "y2network/autoinst/udev_rules_reader" require "y2network/autoinst_profile/networking_section" require "y2network/wicked/interfaces_reader" -require "y2network/reading_result" +require "y2network/issues_result" Yast.import "Stage" @@ -47,7 +47,7 @@ @original_config = original_config end - # @return [ReadingResult] Network configuration + # @return [IssuesResult] Network configuration def read config = Y2Network::Config.new(source: :autoinst) # We need the current interfaces in order to rewrite the config @@ -73,7 +73,7 @@ config.backend = ay_backend - Y2Network::ReadingResult.new(config) + Y2Network::IssuesResult.new(config) end private diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/lib/y2network/config.rb new/yast2-network-4.4.20/src/lib/y2network/config.rb --- old/yast2-network-4.4.18/src/lib/y2network/config.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/src/lib/y2network/config.rb 2021-07-02 08:50:30.000000000 +0200 @@ -70,7 +70,7 @@ # @param source [Symbol] Source to read the configuration from # @param opts [Array<Object>] Reader options. Check readers documentation to find out # supported options. - # @return [ReadingResult] Result of reading the network configuration + # @return [IssuesResult] Result of reading the network configuration def from(source, *opts) reader = ConfigReader.for(source, *opts) reader.read @@ -138,6 +138,8 @@ # @param only [Array<symbol>, nil] explicit sections to be written, by default if no # parameter is given then all changes will be written. # + # @return [IssuesResult] Result of writing the network configuration + # # @see Y2Network::ConfigWriter def write(original: nil, target: nil, only: nil) target = target || backend&.id || source diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/lib/y2network/config_reader.rb new/yast2-network-4.4.20/src/lib/y2network/config_reader.rb --- old/yast2-network-4.4.18/src/lib/y2network/config_reader.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/src/lib/y2network/config_reader.rb 2021-07-02 08:50:30.000000000 +0200 @@ -48,7 +48,7 @@ # Returns the configuration from the given backend # - # @return [Y2Network::ReadingResult] Network configuration + # @return [Y2Network::IssuesResult] Network configuration # @raise NotImplementedError def read raise NotImplementedError diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/lib/y2network/config_writer.rb new/yast2-network-4.4.20/src/lib/y2network/config_writer.rb --- old/yast2-network-4.4.18/src/lib/y2network/config_writer.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/src/lib/y2network/config_writer.rb 2021-07-02 08:50:30.000000000 +0200 @@ -18,10 +18,12 @@ # find current contact information at www.suse.com. require "yast" +require "y2issues" require "y2network/config_writers/dns_writer" require "y2network/config_writers/hostname_writer" require "y2network/config_writers/interfaces_writer" require "y2network/driver" +require "y2network/issues_result" Yast.import "Host" @@ -39,6 +41,7 @@ # not forced to use this class as a base. class ConfigWriter include Yast::Logger + include Yast::I18n class << self # Returns a configuration writer for a given source @@ -64,6 +67,8 @@ # @param old_config [Y2Network::Config] Old configuration # @param only [Array<symbol>, nil] explicit sections to be written, by default if no # parameter is given then all changes will be written + # + # @return [IssuesResult] write result with issues list def write(config, old_config = nil, only: nil) sections = only || SECTIONS @@ -73,11 +78,15 @@ log.info("Writing sections: #{sections.inspect}") if only + issues_list = Y2Issues::List.new + SECTIONS.each do |s| - send(:"write_#{s}", config, old_config) if sections.include?(s) + send(:"write_#{s}", config, old_config, issues_list) if sections.include?(s) end Yast::Host.Write(gui: false) + + IssuesResult.new(config, issues_list) end private @@ -86,19 +95,19 @@ # # @param _config [Y2Network::Config] configuration to write # @param _old_config [Y2Network::Config, nil] original configuration used for detecting changes - def write_routing(_config, _old_config); end + def write_routing(_config, _old_config, _issues_list); end # Writes the connection configurations # # @param _config [Y2Network::Config] configuration to write # @param _old_config [Y2Network::Config, nil] original configuration used for detecting changes - def write_connections(_config, _old_config); end + def write_connections(_config, _old_config, _issues_list); end # Updates the DNS configuration # # @param config [Y2Network::Config] Current config object # @param old_config [Y2Network::Config,nil] Config object with original configuration - def write_dns(config, old_config) + def write_dns(config, old_config, _issues_list) old_dns = old_config.dns if old_config writer = Y2Network::ConfigWriters::DNSWriter.new writer.write(config.dns, old_dns) @@ -108,7 +117,7 @@ # # @param config [Y2Network::Config] Current config object # @param old_config [Y2Network::Config,nil] Config object with original configuration - def write_hostname(config, old_config) + def write_hostname(config, old_config, _issues_list) old_hostname = old_config.hostname if old_config writer = Y2Network::ConfigWriters::HostnameWriter.new writer.write(config.hostname, old_hostname) @@ -119,7 +128,7 @@ # # @param config [Y2Network::Config] Current config object # @param _old_config [Y2Network::Config,nil] Config object with original configuration - def write_interfaces(config, _old_config) + def write_interfaces(config, _old_config, _issues_list) writer = Y2Network::ConfigWriters::InterfacesWriter.new(reload: !Yast::Lan.write_only) writer.write(config.interfaces) end @@ -128,7 +137,7 @@ # # @param config [Y2Network::Config] Current config object # @param _old_config [Y2Network::Config,nil] Config object with original configuration - def write_drivers(config, _old_config) + def write_drivers(config, _old_config, _issues_list) Y2Network::Driver.write_options(config.drivers) end @@ -137,7 +146,7 @@ # TODO: extract this behaviour to a separate class. # # @param routing [Y2Network::Routing] routing configuration - def write_ip_forwarding(routing) + def write_ip_forwarding(routing, issues_list) sysctl_config = CFA::SysctlConfig.new sysctl_config.load sysctl_config.forward_ipv4 = routing.forward_ipv4 @@ -149,6 +158,13 @@ update_ip_forwarding((sysctl_config.forward_ipv6 ? "1" : "0"), :ipv6) nil + rescue CFA::AugeasSerializingError + issues_list << Y2Issues::Issue.new( + "Sysctl configuration update failed. The files might be corrupted", + severity: :error + ) + + nil end IP_SYSCTL = { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/lib/y2network/issues_result.rb new/yast2-network-4.4.20/src/lib/y2network/issues_result.rb --- old/yast2-network-4.4.18/src/lib/y2network/issues_result.rb 1970-01-01 01:00:00.000000000 +0100 +++ new/yast2-network-4.4.20/src/lib/y2network/issues_result.rb 2021-07-02 08:50:30.000000000 +0200 @@ -0,0 +1,43 @@ +# Copyright (c) [2021] SUSE LLC +# +# All Rights Reserved. +# +# This program is free software; you can redistribute it and/or modify it +# under the terms of version 2 of the GNU General Public License as published +# by the Free Software Foundation. +# +# This program is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for +# more details. +# +# You should have received a copy of the GNU General Public License along +# with this program; if not, contact SUSE LLC. +# +# To contact SUSE LLC about this file by physical or electronic mail, you may +# find current contact information at www.suse.com. + +require "yast" +require "y2issues" + +module Y2Network + class IssuesResult + attr_reader :config, :issues + + # Represents a reading operation result + # + # @param config [Config] Read configuration + # @param issues [Errors::List] Errors list + def initialize(config, issues = Y2Issues::List.new) + @config = config + @issues = issues + end + + # Determines whether there is some error + # + # @return [Boolean] + def issues? + issues.any? + end + end +end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/lib/y2network/network_manager/config_writer.rb new/yast2-network-4.4.20/src/lib/y2network/network_manager/config_writer.rb --- old/yast2-network-4.4.18/src/lib/y2network/network_manager/config_writer.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/src/lib/y2network/network_manager/config_writer.rb 2021-07-02 08:50:30.000000000 +0200 @@ -32,7 +32,7 @@ # # @param config [Y2Network::Config] Current config object # @param _old_config [Y2Network::Config,nil] Config object with original configuration - def write_connections(config, _old_config) + def write_connections(config, _old_config, _issues_list) writer = Y2Network::NetworkManager::ConnectionConfigWriter.new config.connections.each do |conn| opts = { @@ -50,7 +50,7 @@ # # @param config [Y2Network::Config] Current config object # @param old_config [Y2Network::Config,nil] Config object with original configuration - def write_dns(config, old_config) + def write_dns(config, old_config, _issues_list) static = config.connections.by_bootproto(Y2Network::BootProtocol::STATIC) return super if static.empty? || config.dns.nameservers.empty? diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/lib/y2network/reading_result.rb new/yast2-network-4.4.20/src/lib/y2network/reading_result.rb --- old/yast2-network-4.4.18/src/lib/y2network/reading_result.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/src/lib/y2network/reading_result.rb 1970-01-01 01:00:00.000000000 +0100 @@ -1,43 +0,0 @@ -# Copyright (c) [2021] SUSE LLC -# -# All Rights Reserved. -# -# This program is free software; you can redistribute it and/or modify it -# under the terms of version 2 of the GNU General Public License as published -# by the Free Software Foundation. -# -# This program is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -# more details. -# -# You should have received a copy of the GNU General Public License along -# with this program; if not, contact SUSE LLC. -# -# To contact SUSE LLC about this file by physical or electronic mail, you may -# find current contact information at www.suse.com. - -require "yast" -require "y2issues" - -module Y2Network - class ReadingResult - attr_reader :config, :issues - - # Represents a reading operation result - # - # @param config [Config] Read configuration - # @param issues [Errors::List] Errors list - def initialize(config, issues = Y2Issues::List.new) - @config = config - @issues = issues - end - - # Determines whether there is some error - # - # @return [Boolean] - def issues? - issues.any? - end - end -end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/lib/y2network/wicked/config_reader.rb new/yast2-network-4.4.20/src/lib/y2network/wicked/config_reader.rb --- old/yast2-network-4.4.18/src/lib/y2network/wicked/config_reader.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/src/lib/y2network/wicked/config_reader.rb 2021-07-02 08:50:30.000000000 +0200 @@ -28,7 +28,7 @@ require "y2network/wicked/hostname_reader" require "y2network/wicked/interfaces_reader" require "y2network/wicked/connection_configs_reader" -require "y2network/reading_result" +require "y2network/issues_result" require "y2issues" Yast.import "Host" @@ -43,7 +43,7 @@ :interfaces, :connections, :drivers, :routing, :dns, :hostname ].freeze - # @return [ReadingResult] Network configuration + # @return [IssuesResult] Network configuration def read # NOTE: This code might be moved outside of the Sysconfig namespace, as it is generic. # NOTE: /etc/hosts cache - nothing to do with /etc/hostname @@ -57,7 +57,7 @@ end log.info "Sysconfig reader result: #{network_config.inspect}" - ReadingResult.new(network_config, issues_list) + IssuesResult.new(network_config, issues_list) end protected diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/lib/y2network/wicked/config_writer.rb new/yast2-network-4.4.20/src/lib/y2network/wicked/config_writer.rb --- old/yast2-network-4.4.18/src/lib/y2network/wicked/config_writer.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/src/lib/y2network/wicked/config_writer.rb 2021-07-02 08:50:30.000000000 +0200 @@ -35,15 +35,15 @@ # # @param config [Y2Network::Config] Current config object # @param old_config [Y2Network::Config,nil] Config object with original configuration - def write_routing(config, old_config) - write_ip_forwarding(config.routing) + def write_routing(config, old_config, issues_list) + write_ip_forwarding(config.routing, issues_list) # update /etc/sysconfig/network/routes file file = routes_file_for(nil) file.routes = find_routes_for(nil, config.routing.routes) file.save - write_interface_routes(config, old_config) + write_interface_routes(config, old_config, issues_list) end # Writes the routes for the configured interfaces removing the ones not @@ -53,7 +53,7 @@ # @param old_config [Y2Network::Config, nil] original configuration used # for detecting changes. When nil, no actions related to # configuration changes are processed. - def write_interface_routes(config, old_config) + def write_interface_routes(config, old_config, _issues_list) # Write ifroute files config.interfaces.each do |dev| # S390 devices that have not been activated yet will be part of the @@ -122,7 +122,7 @@ # # @param config [Y2Network::Config] Current config object # @param old_config [Y2Network::Config,nil] Config object with original configuration - def write_connections(config, old_config) + def write_connections(config, old_config, _issues_list) # FIXME: this code might live in its own class writer = Y2Network::Wicked::ConnectionConfigWriter.new remove_old_connections(config.connections, old_config.connections, writer) if old_config diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/src/modules/Lan.rb new/yast2-network-4.4.20/src/modules/Lan.rb --- old/yast2-network-4.4.18/src/modules/Lan.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/src/modules/Lan.rb 2021-07-02 08:50:30.000000000 +0200 @@ -764,7 +764,7 @@ def read_config(report: true) result = Y2Network::Config.from(:wicked) if result.issues? && report - return false unless Y2Issues.report(result.issues) == :yes + return false unless Y2Issues.report(result.issues) end system_config = result.config @@ -780,8 +780,12 @@ # parameter is given then all changes will be written # # @see Y2Network::ConfigWriter - def write_config(only: nil) - yast_config.write(original: system_config, only: only) + def write_config(only: nil, report: true) + result = yast_config.write(original: system_config, only: only) + if result&.issues? && report + return false unless Y2Issues.report(result.issues) + end + # Force a refresh of the system_config bsc#1162987 add_config(:system, yast_config.copy) end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/test/lan_test.rb new/yast2-network-4.4.20/test/lan_test.rb --- old/yast2-network-4.4.18/test/lan_test.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/test/lan_test.rb 2021-07-02 08:50:30.000000000 +0200 @@ -25,7 +25,7 @@ require "y2network/config" require "y2network/routing" require "y2network/interface_config_builder" -require "y2network/reading_result" +require "y2network/issues_result" Yast.import "Lan" @@ -525,14 +525,14 @@ before do subject.main allow(Y2Network::Config).to receive(:from) - .and_return(Y2Network::ReadingResult.new(system_config, issues_list)) + .and_return(Y2Network::IssuesResult.new(system_config, issues_list)) allow(system_config).to receive(:copy).and_return(system_config_copy) allow(Yast::Lan).to receive(:add_config) end it "reads the Y2Network::Config from sysconfig" do expect(Y2Network::Config).to receive(:from) - .and_return(Y2Network::ReadingResult.new(system_config, issues_list)) + .and_return(Y2Network::IssuesResult.new(system_config, issues_list)) subject.read_config end @@ -556,23 +556,15 @@ end context "when the user asks to continue" do - let(:user_answer) { :yes } + let(:user_answer) { true } it "returns true" do expect(subject.read_config).to eq(true) end end - context "when the user asks to not continue" do - let(:user_answer) { :no } - - it "returns false" do - expect(subject.read_config).to eq(false) - end - end - - context "when the user asks to abort" do - let(:user_answer) { :abort } + context "when the user does not want to continue" do + let(:user_answer) { false } it "returns false" do expect(subject.read_config).to eq(false) @@ -587,7 +579,7 @@ before do subject.main allow(Y2Network::Config).to receive(:from) - .and_return(Y2Network::ReadingResult.new(system_config)) + .and_return(Y2Network::IssuesResult.new(system_config)) subject.read_config allow(Yast::Lan.yast_config).to receive(:write) allow(Yast::Lan.yast_config).to receive(:copy).and_return(yast_config_copy) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-network-4.4.18/test/y2network/config_test.rb new/yast2-network-4.4.20/test/y2network/config_test.rb --- old/yast2-network-4.4.18/test/y2network/config_test.rb 2021-06-17 18:34:19.000000000 +0200 +++ new/yast2-network-4.4.20/test/y2network/config_test.rb 2021-07-02 08:50:30.000000000 +0200 @@ -66,7 +66,7 @@ describe ".from" do let(:reader) do instance_double( - Y2Network::Wicked::ConfigReader, read: Y2Network::ReadingResult.new(config) + Y2Network::Wicked::ConfigReader, read: Y2Network::IssuesResult.new(config) ) end