Hello community,

here is the log from the commit of package yast2-dhcp-server for 
openSUSE:Factory checked in at 2018-09-05 13:48:58
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-dhcp-server (Old)
 and      /work/SRC/openSUSE:Factory/.yast2-dhcp-server.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "yast2-dhcp-server"

Wed Sep  5 13:48:58 2018 rev:54 rq:631396 version:4.1.2

Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-dhcp-server/yast2-dhcp-server.changes      
2018-08-06 11:53:51.261200254 +0200
+++ /work/SRC/openSUSE:Factory/.yast2-dhcp-server.new/yast2-dhcp-server.changes 
2018-09-05 13:49:03.594308409 +0200
@@ -1,0 +2,32 @@
+Fri Aug 24 14:21:19 UTC 2018 - dgonza...@suse.com
+
+- Display an information message instead of the service widget
+  when service is not installed (related to fate#319428).
+- 4.1.2
+
+-------------------------------------------------------------------
+Thu Aug 23 09:38:55 UTC 2018 - dgonza...@suse.com
+
+- Avoid module to crash if service is not installed
+  (related to fate#319428).
+- 4.1.1
+
+-------------------------------------------------------------------
+Mon Aug 20 13:47:16 CEST 2018 - sch...@suse.de
+
+- Switched license in spec file from SPDX2 to SPDX3 format.
+
+-------------------------------------------------------------------
+Tue Aug  13 12:00:22 UTC 2018 - dgonza...@suse.com
+
+- Use CWM::ServiceWidget to manage the service status 
+  (part of fate#319428).
+- 4.1.0
+
+-------------------------------------------------------------------
+Mon Aug 13 10:32:56 UTC 2018 - igonzalezs...@suse.com
+
+- Fix package building with yast2 4.0.84 (bsc#1104644).
+- 4.0.3
+
+-------------------------------------------------------------------

Old:
----
  yast2-dhcp-server-4.0.2.tar.bz2

New:
----
  yast2-dhcp-server-4.1.2.tar.bz2

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ yast2-dhcp-server.spec ++++++
--- /var/tmp/diff_new_pack.Ez6Ody/_old  2018-09-05 13:49:03.962309027 +0200
+++ /var/tmp/diff_new_pack.Ez6Ody/_new  2018-09-05 13:49:03.962309027 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-dhcp-server
-Version:        4.0.2
+Version:        4.1.2
 Release:        0
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
@@ -36,8 +36,8 @@
 BuildRequires:  yast2-dns-server
 BuildRequires:  yast2-perl-bindings
 BuildRequires:  yast2-testsuite
-# UI::ServiceStatus
-BuildRequires:  yast2 >= 3.1.161
+# Yast2::ServiceWidget
+BuildRequires:  yast2 >= 4.1.0
 
 Requires:       bind-utils
 Requires:       perl-Digest-SHA1
@@ -46,8 +46,8 @@
 Requires:       perl-gettext
 Requires:       yast2-ldap
 Requires:       yast2-perl-bindings
-# UI::ServiceStatus
-Requires:       yast2 >= 3.1.161
+# Yast2::ServiceWidget
+Requires:       yast2 >= 4.1.0
 # DnsServerAPI::IsServiceConfigurableExternally
 Requires:       yast2-dns-server >= 2.13.16
 
@@ -56,7 +56,7 @@
 Requires:       yast2-ruby-bindings >= 1.0.0
 
 Summary:        YaST2 - DHCP Server Configuration
-License:        GPL-2.0
+License:        GPL-2.0-only
 Group:          System/YaST
 
 %description

++++++ yast2-dhcp-server-4.0.2.tar.bz2 -> yast2-dhcp-server-4.1.2.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/package/yast2-dhcp-server.changes 
new/yast2-dhcp-server-4.1.2/package/yast2-dhcp-server.changes
--- old/yast2-dhcp-server-4.0.2/package/yast2-dhcp-server.changes       
2018-08-03 15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/package/yast2-dhcp-server.changes       
2018-08-24 17:09:37.000000000 +0200
@@ -1,4 +1,36 @@
 -------------------------------------------------------------------
+Fri Aug 24 14:21:19 UTC 2018 - dgonza...@suse.com
+
+- Display an information message instead of the service widget
+  when service is not installed (related to fate#319428).
+- 4.1.2
+
+-------------------------------------------------------------------
+Thu Aug 23 09:38:55 UTC 2018 - dgonza...@suse.com
+
+- Avoid module to crash if service is not installed
+  (related to fate#319428).
+- 4.1.1
+
+-------------------------------------------------------------------
+Mon Aug 20 13:47:16 CEST 2018 - sch...@suse.de
+
+- Switched license in spec file from SPDX2 to SPDX3 format.
+
+-------------------------------------------------------------------
+Tue Aug  13 12:00:22 UTC 2018 - dgonza...@suse.com
+
+- Use CWM::ServiceWidget to manage the service status 
+  (part of fate#319428).
+- 4.1.0
+
+-------------------------------------------------------------------
+Mon Aug 13 10:32:56 UTC 2018 - igonzalezs...@suse.com
+
+- Fix package building with yast2 4.0.84 (bsc#1104644).
+- 4.0.3
+
+-------------------------------------------------------------------
 Fri Aug  3 09:39:35 UTC 2018 - igonzalezs...@suse.com
 
 - Fix package building with yast2 4.0.80 (bsc#1103691).
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/package/yast2-dhcp-server.spec 
new/yast2-dhcp-server-4.1.2/package/yast2-dhcp-server.spec
--- old/yast2-dhcp-server-4.0.2/package/yast2-dhcp-server.spec  2018-08-03 
15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/package/yast2-dhcp-server.spec  2018-08-24 
17:09:37.000000000 +0200
@@ -17,22 +17,22 @@
 
 
 Name:           yast2-dhcp-server
-Version:        4.0.2
+Version:        4.1.2
 Release:        0
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 Source0:        %{name}-%{version}.tar.bz2
 
 Group:          System/YaST
-License:        GPL-2.0
+License:        GPL-2.0-only
 BuildRequires: perl-Digest-SHA1 perl-X500-DN perl-XML-Writer 
docbook-xsl-stylesheets doxygen libxslt perl-XML-Writer popt-devel sgml-skel 
update-desktop-files yast2-perl-bindings yast2-testsuite yast2-dns-server
 BuildRequires:  yast2-devtools >= 3.1.10
-# UI::ServiceStatus
-BuildRequires:  yast2 >= 3.1.161
+# Yast2::ServiceWidget
+BuildRequires:  yast2 >= 4.1.0
 
 Requires:       perl-gettext yast2-perl-bindings bind-utils perl-X500-DN 
yast2-ldap perl-Digest-SHA1 perl-Parse-RecDescent
-# UI::ServiceStatus
-Requires:       yast2 >= 3.1.161
+# Yast2::ServiceWidget
+Requires:       yast2 >= 4.1.0
 # DnsServerAPI::IsServiceConfigurableExternally
 Requires:       yast2-dns-server >= 2.13.16
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/src/include/dhcp-server/dialogs.rb 
new/yast2-dhcp-server-4.1.2/src/include/dhcp-server/dialogs.rb
--- old/yast2-dhcp-server-4.0.2/src/include/dhcp-server/dialogs.rb      
2018-08-03 15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/src/include/dhcp-server/dialogs.rb      
2018-08-24 17:09:37.000000000 +0200
@@ -10,8 +10,13 @@
 #
 # Representation of the configuration of dhcp-server.
 # Input and output routines.
+
+require "yast2/popup"
+
 module Yast
   module DhcpServerDialogsInclude
+    include Yast::Logger
+
     def initialize_dhcp_server_dialogs(include_target)
       textdomain "dhcp-server"
 
@@ -23,6 +28,7 @@
       Yast.import "Popup"
       Yast.import "Label"
       Yast.import "Confirm"
+      Yast.import "Mode"
 
       @functions = { :abort => fun_ref(method(:confirmAbort), "boolean ()") }
     end
@@ -47,44 +53,69 @@
     end
 
     # Write settings dialog
-    # @return `abort if aborted and `next otherwise
+    #
+    # @return [Symbol] :next whether configuration is saved successfully
+    #                  :back if user decided to go back to change settings
+    #                  :abort otherwise
     def WriteDialog
-      Builtins.y2milestone("Running write dialog")
-      Wizard.RestoreHelp(Ops.get(@HELPS, "write", ""))
-      ret = DhcpServer.Write
-      if ret && restart_after_writing?
-        # Restart only if it's already running
-        DhcpServerUI.service.try_restart
-      end
-      # yes-no popup
-      if !ret &&
-          Popup.YesNo(
-            _("Saving the configuration failed. Change the settings?")
-          )
-        return :back
-      end
-      ret ? :next : :abort
+      help_text = @HELPS.fetch("write", "")
+      Wizard.RestoreHelp(help_text)
+
+      return :next if write_settings
+      return :back if back_to_change_setting?
+      :abort
     end
 
     # Write settings without quitting
     def SaveAndRestart(event)
-      return nil unless CWM.validate_current_widgets(event)
-      CWM.save_current_widgets(event)
+      return nil unless validate_and_save_widgets(event)
+
+      help_text = @HELPS.fetch("write", "")
 
       Wizard.CreateDialog
-      Wizard.RestoreHelp(Ops.get(@HELPS, "write", ""))
-      ret = DhcpServer.Write
-      if ret
-        # Restart only if it's already running
-        DhcpServerUI.service.try_restart if restart_after_writing?
-      else
-        Report.Error(_("Saving the configuration failed"))
-      end
-      UI.CloseDialog
+      Wizard.RestoreHelp(help_text)
+      Report.Error(_("Saving the configuration failed")) unless write_settings
+      Wizard.CloseDialog
+
+      service_widget.refresh if service
 
       nil
     end
 
+    # Write DHCP server settings and save the service
+    #
+    # @note currently, the DhpcServer is a Perl module, reason why the write of
+    # settings is being performed in two separate steps.
+    #
+    # @return [Boolean] true if settings are saved successfully; false 
otherwise
+    def write_settings
+      return false unless DhcpServer.Write
+      return true unless service
+
+      service.save(keep_state: Mode.auto)
+    end
+
+    # Shows a popup asking to user if wants to change settings
+    #
+    # @return [Boolean] true if user decides to go back to change settings; 
false otherwise
+    def back_to_change_setting?
+      change_settings_message = _("Saving the configuration failed. Change the 
settings?")
+      Yast2::Popup.show(change_settings_message, headline: :warning, buttons: 
:yes_no) == :yes
+    end
+
+    # Validates and saves CWM widgets
+    #
+    # @param [Hash] event map that triggered saving
+    #
+    # @return [Boolean] true when widgets pass the validaton; false otherwise
+    def validate_and_save_widgets(event)
+      return false unless CWM.validate_current_widgets(event)
+
+      CWM.save_current_widgets(event)
+
+      true
+    end
+
     # Run main dialog
     # @return [Symbol] for wizard sequencer
     def OldMainDialog
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/src/include/dhcp-server/dialogs2.rb 
new/yast2-dhcp-server-4.1.2/src/include/dhcp-server/dialogs2.rb
--- old/yast2-dhcp-server-4.0.2/src/include/dhcp-server/dialogs2.rb     
2018-08-03 15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/src/include/dhcp-server/dialogs2.rb     
2018-08-24 17:09:37.000000000 +0200
@@ -80,7 +80,7 @@
       @tabs = {
         "start_up"        => {
           "contents"        => VBox(
-            "service_status",
+            "service_widget",
             VSpacing(),
             "use_ldap",
             VSpacing(),
@@ -97,7 +97,7 @@
           # tree item
           "tree_item_label" => _("Start-Up"),
           "widget_names"    => [
-            "service_status",
+            "service_widget",
             "use_ldap",
             "expert_settings",
             "other_options",
@@ -171,7 +171,7 @@
         "inst_summary"    => {
           "contents"     => VBox(
             VSpacing(1),
-            "auto_start_up",
+            "service_widget",
             VSpacing(1),
             "config_summary",
             VSpacing(1),
@@ -181,7 +181,7 @@
           # dialog caption
           "wizard"       => _("Start-Up"),
           "widget_names" => [
-            "auto_start_up",
+            "service_widget",
             "config_summary",
             "all_settings_button"
           ]
@@ -192,29 +192,6 @@
         Builtins.union(
           @widgets,
           {
-            "auto_start_up"   => CWMServiceStart.CreateAutoStartWidget(
-              {
-                "get_service_auto_start" => fun_ref(
-                  method(:GetStartService),
-                  "boolean ()"
-                ),
-                "set_service_auto_start" => fun_ref(
-                  method(:SetStartService),
-                  "void (boolean)"
-                ),
-                # radio button
-                "start_auto_button"      => _("When &Booting"),
-                # radio button
-                "start_manual_button"    => _("&Manually"),
-                "help"                   => Builtins.sformat(
-                  CWMServiceStart.AutoStartHelpTemplate,
-                  # part of help text - radio button label, NO SHORTCUT!!!
-                  _("When Booting"),
-                  # part of help text - radio button label, NO SHORTCUT!!!
-                  _("Manually")
-                )
-              }
-            ),
             "use_ldap"        => CWMServiceStart.CreateLdapWidget(
               {
                 "get_use_ldap" => fun_ref(
@@ -2132,16 +2109,6 @@
 
       nil
     end
-
-    def GetStartService
-      DhcpServer.GetStartService
-    end
-
-    def SetStartService(start)
-      DhcpServer.SetStartService(start)
-
-      nil
-    end
 
     # Common Config Dialog
     # @return [Symbol] for the wizard sequencer
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/src/include/dhcp-server/widgets.rb 
new/yast2-dhcp-server-4.1.2/src/include/dhcp-server/widgets.rb
--- old/yast2-dhcp-server-4.0.2/src/include/dhcp-server/widgets.rb      
2018-08-03 15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/src/include/dhcp-server/widgets.rb      
2018-08-24 17:09:37.000000000 +0200
@@ -7,7 +7,9 @@
 # Authors:     Jiri Srain <jsr...@suse.cz>
 
 require "yast"
-require "ui/service_status"
+require "yast2/system_service"
+require "cwm"
+require "cwm/service_widget"
 
 # Representation of the configuration of dhcp-server.
 # Input and output routines.
@@ -27,22 +29,20 @@
       Yast.import "TablePopup"
       Yast.import "SuSEFirewall"
       Yast.import "Mode"
-      Yast.import "DhcpServerUI"
     end
 
-    # Widget to handle the status of the service
+    # Returns the service for DHCP
     #
-    # @return [::UI::ServiceStatus] nil if the service is not found (dhcp 
server
-    #                               not installed)
-    def status_widget
-      return @status_widget unless @status_widget.nil?
+    # @return [Yast2::SystemService] status service
+    def service
+      @service ||= Yast2::SystemService.find(DhcpServer.ServiceName)
+    end
 
-      service = DhcpServerUI.service
-      if service
-        @status_widget = ::UI::ServiceStatus.new(service, reload_flag_label: 
:restart)
-      else
-        nil
-      end
+    # Widget to define status and start mode of the service
+    #
+    # @return [::CWM::ServiceWidget]
+    def service_widget
+      @service_widget ||= ::CWM::ServiceWidget.new(service)
     end
 
     # Function for deleting entry from section
@@ -855,47 +855,15 @@
 
     # Handle function for the 'Apply' button
     def handle_apply(_key, event)
-      event_id = event["ID"]
-      if event_id == "apply"
-        SaveAndRestart(event)
-      end
-      nil
-    end
+      SaveAndRestart(event) if event["ID"] == "apply"
 
-    def init_service_status(_key)
-      # If UI::ServiceStatus is used, do not let DnsServer manage the service
-      # status, let the user decide
-      DhcpServer.SetWriteOnly(true)
       nil
     end
 
-    # Handle function for the ServiceStatus widget
-    def handle_service_status(_key, event)
-      event_id = event["ID"]
-      if status_widget.handle_input(event_id) == :enabled_flag
-        DhcpServer.SetModified
-      end
-      nil
-    end
-
-    # Store settings of the widget
-    # @param [String] id string widget id
-    # @param [Hash] event map event that caused storing process
-    def store_service_status(_key, _event)
-      DhcpServer.SetStartService(status_widget.enabled_flag?)
-      nil
-    end
-
-    # Checks if the service must be restarted after saving
-    # @return [Boolean]
-    def restart_after_writing?
-      # If ServiceStatus is used, DhcpServer must be set to write-only
-      DhcpServer.GetWriteOnly() && status_widget && status_widget.reload_flag?
-    end
-
     # Initialize widgets
+    #
     # Create description map and copy it into appropriate variable of the
-    #  DhcpServer module
+    # DhcpServer module
     def InitWidgets
       options = [
         "option subnet-mask",
@@ -1326,16 +1294,30 @@
     # it needs the "dhcp-server" package already installed in the system
     # otherwise it crashes
     def InitServiceWidget
-      return if @widgets["service_status"]
+      return if @widgets["service_widget"]
 
-      @widgets["service_status"] = {
-        "widget" => :custom,
-        "custom_widget" => status_widget.widget,
-        "help"   => status_widget.help,
-        "init"   => fun_ref(method(:init_service_status), "void (string)"),
-        "handle" => fun_ref(method(:handle_service_status), "symbol (string, 
map)"),
-        "store"  => fun_ref(method(:store_service_status), "void (string, 
map)")
-      }
+      @widgets["service_widget"] = service_widget_content
+    end
+
+  private
+
+    # Returns the content to be displayed in the start up section
+    #
+    # Depending on whether the `dhcpd` is installed or not, it will return a
+    #
+    #   * ServiceWidget definition (when installed)
+    #   * Label with an information message (when not)
+    #
+    # @return [Hash]
+    def service_widget_content
+      if service
+        service_widget.cwm_definition
+      else
+        {
+          "widget"        => :custom,
+          "custom_widget" => Left(Label(_("Service dhcpd is not installed")))
+        }
+      end
     end
   end
 end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-dhcp-server-4.0.2/src/modules/DhcpServer.pm 
new/yast2-dhcp-server-4.1.2/src/modules/DhcpServer.pm
--- old/yast2-dhcp-server-4.0.2/src/modules/DhcpServer.pm       2018-08-03 
15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/src/modules/DhcpServer.pm       2018-08-24 
17:09:37.000000000 +0200
@@ -1745,33 +1745,6 @@
     SCR->Write (".sysconfig.dhcpd.DHCPD_INTERFACE", $ifaces_list);
     SCR->Write (".sysconfig.dhcpd.DHCPD_OTHER_ARGS", $other_options);
     SCR->Write (".sysconfig.dhcpd", undef);
-       
-
-    if ($start_service)
-    {
-       y2milestone ("Enabling the DHCP service");
-       my $ret = 1;
-       if (! $write_only)
-       {
-           $ret = Service->Restart ($SERVICE);
-       }
-       Service->Enable ($SERVICE);
-       if (!$ret)
-       {
-           # error report
-           Report->Error (__("Error occurred while restarting the DHCP 
daemon."));
-           $ok = 0;
-       }
-    }
-    else
-    {
-       y2milestone ("Disabling the DHCP service");
-       if (! $write_only)
-       {
-           Service->Stop ($SERVICE);
-       }
-       Service->Disable ($SERVICE);
-    }
 
     Progress->NextStage ();
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-dhcp-server-4.0.2/src/modules/DhcpServerUI.rb 
new/yast2-dhcp-server-4.1.2/src/modules/DhcpServerUI.rb
--- old/yast2-dhcp-server-4.0.2/src/modules/DhcpServerUI.rb     2018-08-03 
15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/src/modules/DhcpServerUI.rb     2018-08-24 
17:09:37.000000000 +0200
@@ -22,9 +22,7 @@
       Yast.import "Mode"
       Yast.import "Popup"
       Yast.import "Report"
-      Yast.import "Service"
       Yast.import "SuSEFirewall"
-      Yast.import "SystemdService"
 
       @current_entry_type = ""
       @current_entry_id = ""
@@ -82,13 +80,6 @@
       nil
     end
 
-    # Object representing the DHCP service for its usage in the UI code
-    #
-    # @return [Yast::SystemdServiceClass::Service]
-    def service
-      @service ||= SystemdService.find(DhcpServer.ServiceName())
-    end
-
     publish :variable => :current_entry_type, :type => "string"
     publish :variable => :current_entry_id, :type => "string"
     publish :variable => :current_entry_options, :type => "list <map <string, 
string>>"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-dhcp-server-4.0.2/test/dialog_test.rb 
new/yast2-dhcp-server-4.1.2/test/dialog_test.rb
--- old/yast2-dhcp-server-4.0.2/test/dialog_test.rb     1970-01-01 
01:00:00.000000000 +0100
+++ new/yast2-dhcp-server-4.1.2/test/dialog_test.rb     2018-08-24 
17:09:37.000000000 +0200
@@ -0,0 +1,159 @@
+#!/usr/bin/env rspec
+# encoding: utf-8
+# Copyright (c) [2018] 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_relative "test_helper"
+
+require "yast2/system_service"
+require "cwm/service_widget"
+
+Yast.import "DhcpServer"
+
+describe "DhcpServerDialogsInclude" do
+    subject(:dialog) { TestDialog.new }
+
+  class TestDialog
+    include Yast::I18n
+    include Yast::UIShortcuts
+
+    def initialize
+      @HELPS = {}
+      Yast.include self, "dhcp-server/widgets.rb"
+      Yast.include self, "dhcp-server/dialogs.rb"
+    end
+
+    def fun_ref(*args)
+    end
+  end
+
+  let(:widget) { instance_double(::CWM::ServiceWidget, cwm_definition: {}) }
+  let(:service) { instance_double(Yast2::SystemService, save: true, 
currently_active?: true) }
+
+  before do
+    allow(::CWM::ServiceWidget).to receive(:new).and_return(widget)
+    allow(Yast2::SystemService).to 
receive(:find).with("dhcpd").and_return(service)
+    allow(Yast::DhcpServer).to 
receive(:Write).and_return(dhcp_configuration_written)
+  end
+
+  let(:dhcp_configuration_written) { true }
+
+  describe "#SaveAndRestart" do
+    before do
+      allow(dialog).to receive(:validate_and_save_widgets).and_return(true)
+      allow(dialog).to receive(:write_settings).and_return(true)
+    end
+
+    let(:event) { { "ID": ":next"} }
+
+    context "when service is installed" do
+      it "refreshes the service widget" do
+        expect(widget).to receive(:refresh)
+
+        dialog.SaveAndRestart(event)
+      end
+    end
+
+    context "when service is not installed" do
+      let(:service) { nil }
+
+      it "does not refresh the service widget" do
+        expect(widget).to_not receive(:refresh)
+
+        dialog.SaveAndRestart(event)
+      end
+    end
+  end
+
+  describe "#WriteDialog" do
+    it "writes needed configuration" do
+      expect(Yast::DhcpServer).to receive(:Write)
+
+      dialog.WriteDialog
+    end
+
+    context "when configuration is written" do
+      it "saves the system service" do
+        expect(service).to receive(:save)
+
+        dialog.WriteDialog
+      end
+
+      it "returns :next" do
+        expect(dialog.WriteDialog).to eq(:next)
+      end
+
+      context "and is in `auto` Mode" do
+        before do
+          allow(Yast::Mode).to receive(:auto).and_return(true)
+        end
+
+        it "keeps current system status" do
+          expect(service).to receive(:save).with(hash_including(keep_state: 
true))
+
+          dialog.WriteDialog
+        end
+      end
+
+      context "and service is not installed" do
+        let(:service) { nil }
+
+        it "does not try to save the service" do
+          expect(service).to_not receive(:save)
+        end
+      end
+    end
+
+    context "when the configuration is not written" do
+      before do
+        allow(Yast2::Popup).to receive(:show).and_return(change_settings)
+      end
+
+      let(:change_settings) { :yes }
+      let(:dhcp_configuration_written) { false }
+
+      it "does not save the system service" do
+        expect(service).to_not receive(:save)
+
+        dialog.WriteDialog
+      end
+
+      it "asks for changing the current settings" do
+        expect(Yast2::Popup).to receive(:show)
+          .with(instance_of(String), hash_including(buttons: :yes_no))
+
+        dialog.WriteDialog
+      end
+
+      context "and user decides to change the current setting" do
+        it "returns :back" do
+          expect(dialog.WriteDialog).to eq(:back)
+        end
+      end
+
+      context "and user decides to cancel" do
+        let(:change_settings) { :no }
+
+        it "returns :abort" do
+          expect(subject.WriteDialog).to eq(:abort)
+        end
+      end
+    end
+  end
+end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-dhcp-server-4.0.2/test/widgets_test.rb 
new/yast2-dhcp-server-4.1.2/test/widgets_test.rb
--- old/yast2-dhcp-server-4.0.2/test/widgets_test.rb    2018-08-03 
15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/test/widgets_test.rb    2018-08-24 
17:09:37.000000000 +0200
@@ -10,8 +10,6 @@
   end
 end
 
-
-
 describe "Yast::DhcpServerWidgetsInclude" do
   subject { Yast::Test.new }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yast2-dhcp-server-4.0.2/testsuite/tests/Write.out 
new/yast2-dhcp-server-4.1.2/testsuite/tests/Write.out
--- old/yast2-dhcp-server-4.0.2/testsuite/tests/Write.out       2018-08-03 
15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/testsuite/tests/Write.out       2018-08-24 
17:09:37.000000000 +0200
@@ -3,16 +3,6 @@
 Write  .sysconfig.dhcpd.DHCPD_INTERFACE "" true
 Write  .sysconfig.dhcpd.DHCPD_OTHER_ARGS "" true
 Write  .sysconfig.dhcpd nil true
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password is-enabled dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password stop dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password is-enabled dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password is-enabled dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password disable dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password is-enabled dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
 Return true
 Dump   ===============================
 Return nil
@@ -22,14 +12,4 @@
 Write  .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2" true
 Write  .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111" true
 Write  .sysconfig.dhcpd nil true
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password is-enabled dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password stop dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password is-enabled dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password is-enabled dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password disable dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"", "stdout":""]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password is-enabled dhcpd.service " $["exit":0, 
"stderr":"", "stdout":""]
 Return true
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPIAddDeclaration.out 
new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPIAddDeclaration.out
--- old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPIAddDeclaration.out  
2018-08-03 15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPIAddDeclaration.out  
2018-08-24 17:09:37.000000000 +0200
@@ -1,7 +1,7 @@
 Dump   ==========================================================
 Execute        .target.bash_output "/bin/hostname --short" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Execute        .target.bash_output "/bin/hostname --fqdn" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
+Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload " $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Read   .sysconfig.dhcpd.DHCPD_RUN_CHROOTED "no"
 Read   .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2"
 Read   .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111"
@@ -14,7 +14,5 @@
 Write  .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2" true
 Write  .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111" true
 Write  .sysconfig.dhcpd nil true
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
 Return true
 Dump   ==========================================================
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPIDeleteDeclartion.out 
new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPIDeleteDeclartion.out
--- old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPIDeleteDeclartion.out        
2018-08-03 15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPIDeleteDeclartion.out        
2018-08-24 17:09:37.000000000 +0200
@@ -1,7 +1,7 @@
 Dump   ==========================================================
 Execute        .target.bash_output "/bin/hostname --short" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Execute        .target.bash_output "/bin/hostname --fqdn" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
+Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload " $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Read   .sysconfig.dhcpd.DHCPD_RUN_CHROOTED "no"
 Read   .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2"
 Read   .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111"
@@ -14,13 +14,11 @@
 Write  .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2" true
 Write  .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111" true
 Write  .sysconfig.dhcpd nil true
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
 Return true
 Dump   ==========================================================
 Execute        .target.bash_output "/bin/hostname --short" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Execute        .target.bash_output "/bin/hostname --fqdn" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
+Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload " $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Read   .sysconfig.dhcpd.DHCPD_RUN_CHROOTED "no"
 Read   .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2"
 Read   .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111"
@@ -33,7 +31,5 @@
 Write  .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2" true
 Write  .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111" true
 Write  .sysconfig.dhcpd nil true
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
 Return true
 Dump   ==========================================================
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPISetDeclarationDirectives.out 
new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPISetDeclarationDirectives.out
--- 
old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPISetDeclarationDirectives.out    
    2018-08-03 15:02:10.000000000 +0200
+++ 
new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPISetDeclarationDirectives.out    
    2018-08-24 17:09:37.000000000 +0200
@@ -1,7 +1,7 @@
 Dump   ==========================================================
 Execute        .target.bash_output "/bin/hostname --short" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Execute        .target.bash_output "/bin/hostname --fqdn" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
+Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload " $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Read   .sysconfig.dhcpd.DHCPD_RUN_CHROOTED "no"
 Read   .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2"
 Read   .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111"
@@ -14,7 +14,5 @@
 Write  .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2" true
 Write  .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111" true
 Write  .sysconfig.dhcpd nil true
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
 Return true
 Dump   ==========================================================
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPISetDeclarationOptions.out 
new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPISetDeclarationOptions.out
--- old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPISetDeclarationOptions.out   
2018-08-03 15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPISetDeclarationOptions.out   
2018-08-24 17:09:37.000000000 +0200
@@ -1,7 +1,7 @@
 Dump   ==========================================================
 Execute        .target.bash_output "/bin/hostname --short" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Execute        .target.bash_output "/bin/hostname --fqdn" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
+Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload " $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Read   .sysconfig.dhcpd.DHCPD_RUN_CHROOTED "no"
 Read   .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2"
 Read   .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111"
@@ -14,7 +14,5 @@
 Write  .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2" true
 Write  .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111" true
 Write  .sysconfig.dhcpd nil true
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
 Return true
 Dump   ==========================================================
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPISetDeclarationParent.out 
new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPISetDeclarationParent.out
--- old/yast2-dhcp-server-4.0.2/testsuite/tests/YaPISetDeclarationParent.out    
2018-08-03 15:02:10.000000000 +0200
+++ new/yast2-dhcp-server-4.1.2/testsuite/tests/YaPISetDeclarationParent.out    
2018-08-24 17:09:37.000000000 +0200
@@ -1,7 +1,7 @@
 Dump   ==========================================================
 Execute        .target.bash_output "/bin/hostname --short" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Execute        .target.bash_output "/bin/hostname --fqdn" $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
+Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload " $["exit":0, 
"stderr":"localhost", "stdout":"localhost"]
 Read   .sysconfig.dhcpd.DHCPD_RUN_CHROOTED "no"
 Read   .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2"
 Read   .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111"
@@ -14,7 +14,5 @@
 Write  .sysconfig.dhcpd.DHCPD_INTERFACE "eth0 eth2" true
 Write  .sysconfig.dhcpd.DHCPD_OTHER_ARGS "-p 111" true
 Write  .sysconfig.dhcpd nil true
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
-Execute        .target.bash_output " LANG=C TERM=dumb COLUMNS=1024 systemctl 
--no-legend --no-pager --no-ask-password show dhcpd.service  --property=Id  
--property=MainPID  --property=Description  --property=LoadState  
--property=ActiveState  --property=SubState  --property=UnitFileState  
--property=FragmentPath  --property=CanReload  --property=TriggeredBy " 
$["exit":0, "stderr":"localhost", "stdout":"localhost"]
 Return true
 Dump   ==========================================================


Reply via email to