Hello community, here is the log from the commit of package yast2-mail for openSUSE:Factory checked in at 2020-05-15 23:49:47 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/yast2-mail (Old) and /work/SRC/openSUSE:Factory/.yast2-mail.new.2738 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-mail" Fri May 15 23:49:47 2020 rev:92 rq:802999 version:4.3.0 Changes: -------- --- /work/SRC/openSUSE:Factory/yast2-mail/yast2-mail.changes 2019-08-30 14:37:27.561461319 +0200 +++ /work/SRC/openSUSE:Factory/.yast2-mail.new.2738/yast2-mail.changes 2020-05-15 23:49:49.313255699 +0200 @@ -1,0 +2,7 @@ +Tue May 12 12:51:56 UTC 2020 - Josef Reidinger <jreidin...@suse.com> + +- Autoyast schema: Allow optional types for string and map objects + (bsc#1170886) +- 4.3.0 + +------------------------------------------------------------------- Old: ---- yast2-mail-4.2.2.tar.bz2 New: ---- yast2-mail-4.3.0.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2-mail.spec ++++++ --- /var/tmp/diff_new_pack.XemUu4/_old 2020-05-15 23:49:51.057259060 +0200 +++ /var/tmp/diff_new_pack.XemUu4/_new 2020-05-15 23:49:51.061259067 +0200 @@ -1,7 +1,7 @@ # # spec file for package yast2-mail # -# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,7 +17,7 @@ Name: yast2-mail -Version: 4.2.2 +Version: 4.3.0 Release: 0 Summary: YaST2 - Mail Configuration License: GPL-2.0-or-later ++++++ yast2-mail-4.2.2.tar.bz2 -> yast2-mail-4.3.0.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/.travis.yml new/yast2-mail-4.3.0/.travis.yml --- old/yast2-mail-4.2.2/.travis.yml 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/.travis.yml 2020-05-12 15:29:02.000000000 +0200 @@ -8,4 +8,4 @@ script: # the "yast-travis-ruby" script is included in the base yastdevel/ruby image # see https://github.com/yast/docker-yast-ruby/blob/master/yast-travis-ruby - - docker run -it --rm -e TRAVIS=1 -e TRAVIS_JOB_ID="$TRAVIS_JOB_ID" -e PERL5LIB=./src/servers_non_y2 yast-mail-image yast-travis-ruby + - docker run -it --privileged --rm -e TRAVIS=1 -e TRAVIS_JOB_ID="$TRAVIS_JOB_ID" -e PERL5LIB=./src/servers_non_y2 yast-mail-image yast-travis-ruby diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/CONTRIBUTING.md new/yast2-mail-4.3.0/CONTRIBUTING.md --- old/yast2-mail-4.2.2/CONTRIBUTING.md 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/CONTRIBUTING.md 1970-01-01 01:00:00.000000000 +0100 @@ -1,89 +0,0 @@ -YaST Contribution Guidelines -============================ - -YaST is an open source project and as such it welcomes all kinds of -contributions. If you decide to contribute, please follow these guidelines to -ensure the process is effective and pleasant both for you and the YaST maintainers. - -There are two main forms of contribution: reporting bugs and performing code -changes. - -Bug Reports ------------ - -If you find a problem, please report it either using -[Bugzilla](https://bugzilla.suse.com/enter_bug.cgi?format=guided&product=openSUSE+Factory&component=YaST2) -or [GitHub issues](../../issues). (For Bugzilla, use the [simplified -registration](https://secure-www.novell.com/selfreg/jsp/createSimpleAccount.jsp) -if you don't have an account yet.) - -When creating a bug report, please follow our [bug reporting -guidelines](http://en.opensuse.org/openSUSE:Report_a_YaST_bug). - -We can't guarantee that every bug will be fixed, but we'll try. - -Code Changes ------------- - -We welcome all kinds of code contributions, from simple bug fixes to significant -refactorings and implementation of new features. However, before making any -non-trivial contribution, get in touch with us first — this can prevent wasted -effort on both sides. Also, have a look at our [development -documentation](http://en.opensuse.org/openSUSE:YaST_development). - -To send us your code change, use GitHub pull requests. The workflow is as -follows: - - 1. Fork the project. - - 2. Create a topic branch based on `master`. - - 3. Implement your change, including tests (if possible). Make sure you adhere - to the [Ruby style - guide](https://github.com/SUSE/style-guides/blob/master/Ruby.md). - - 4. Update the package version (in `packages/*.spec`, usually by - `rake version:bump`) and add a new entry to the `package/*.changes` file - (by `osc vc package`). - For bigger changes or changes which need longer discussion it is advised to - add this as a separate last commit so it can be easily updated when another - change is merged in the meantime. - - 5. Make sure your change didn't break anything by building the RPM package - (`rake osc:build`). The build process includes running the full testsuite. - - 6. Publish the branch and create a pull request. - - 7. YaST developers will review your change and possibly point out issues. - Adapt the code under their guidance until they are all resolved. - - 8. Finally, the pull request will get merged or rejected. - -See also [GitHub's guide on -contributing](https://help.github.com/articles/fork-a-repo). - -If you want to do multiple unrelated changes, use separate branches and pull -requests. - -### Commits - -Each commit in the pull request should do only one thing, which is clearly -described by its commit message. Especially avoid mixing formatting changes and -functional changes into one commit. When writing commit messages, adhere to -[widely used -conventions](http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html). - -If your commit is related to a bug in Bugzilla or an issue on GitHub, make sure -you mention it in the commit message for cross-reference. Use format like -bnc#775814 or gh#yast/yast-foo#42. See also [GitHub -autolinking](https://help.github.com/articles/github-flavored-markdown#references) -and [openSUSE abbreviation -reference](http://en.opensuse.org/openSUSE:Packaging_Patches_guidelines#Current_set_of_abbreviations). - -Additional Information ----------------------- - -If you have any question, feel free to ask at the [development mailing -list](http://lists.opensuse.org/yast-devel/) or at the -[#yast](http://webchat.freenode.net/?channels=%23yast) IRC channel on freenode. -We'll do our best to provide a timely and accurate answer. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/package/yast2-mail.changes new/yast2-mail-4.3.0/package/yast2-mail.changes --- old/yast2-mail-4.2.2/package/yast2-mail.changes 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/package/yast2-mail.changes 2020-05-12 15:29:02.000000000 +0200 @@ -1,4 +1,11 @@ ------------------------------------------------------------------- +Tue May 12 12:51:56 UTC 2020 - Josef Reidinger <jreidin...@suse.com> + +- Autoyast schema: Allow optional types for string and map objects + (bsc#1170886) +- 4.3.0 + +------------------------------------------------------------------- Tue Aug 27 18:06:21 CEST 2019 - sch...@suse.de - Set X-SuSE-YaST-AutoInstResource in desktop file (bsc#144894). diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/package/yast2-mail.spec new/yast2-mail-4.3.0/package/yast2-mail.spec --- old/yast2-mail-4.2.2/package/yast2-mail.spec 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/package/yast2-mail.spec 2020-05-12 15:29:02.000000000 +0200 @@ -16,7 +16,7 @@ # Name: yast2-mail -Version: 4.2.2 +Version: 4.3.0 Release: 0 Summary: YaST2 - Mail Configuration License: GPL-2.0-or-later diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/src/autoyast-rnc/mail.rnc new/yast2-mail-4.3.0/src/autoyast-rnc/mail.rnc --- old/yast2-mail-4.2.2/src/autoyast-rnc/mail.rnc 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/src/autoyast-rnc/mail.rnc 2020-05-12 15:29:02.000000000 +0200 @@ -2,38 +2,49 @@ namespace a = "http://relaxng.org/ns/compatibility/annotations/1.0" namespace config = "http://www.suse.com/1.0/configns" +include "common.rnc" + mail = element mail { - aliases? & - connection_type & - fetchmail? & - from_header? & - listen_remote? & - local_domains? & - mail_smtp_auth? & - masquerade_other_domains? & - masquerade_users? & - mta & - outgoing_mail_server? & - postfix_mda? & - smtp_use_TLS? & - system_mail_sender? & - use_amavis? & - use_dkim? & - virtual_users? + MAP, + ( + aliases? & + connection_type & + fetchmail? & + from_header? & + listen_remote? & + local_domains? & + mail_smtp_auth? & + masquerade_other_domains? & + masquerade_users? & + mta & + outgoing_mail_server? & + postfix_mda? & + smtp_use_TLS? & + system_mail_sender? & + use_amavis? & + use_dkim? & + virtual_users? + ) } # we have code to accept it as symbol or string mail_SYMBOL_OR_TEXT = - attribute config:type { "symbol" }? + ( + attribute config:type { "symbol" }? | + STRING_ATTR + ) aliases = element aliases { LIST, element alias { - element alias { text } & - element destinations { text } & - element comment { text }? + MAP, + ( + element alias { STRING } & + element destinations { STRING } & + element comment { STRING }? + ) }* } @@ -47,37 +58,40 @@ element fetchmail { LIST, element fetchmail_entry { - element server { text } & - element protocol { text } & - element remote_user { text } & - element local_user { text } & - element password { text } + MAP, + ( + element server { STRING } & + element protocol { STRING } & + element remote_user { STRING } & + element local_user { STRING } & + element password { STRING } + ) }+ } -from_header = element from_header { text } +from_header = element from_header { STRING } listen_remote = element listen_remote { BOOLEAN } local_domains = element local_domains { LIST, - element domains { text }* + element domains { STRING }* } masquerade_other_domains = element masquerade_other_domains { LIST, - element domain { text }* + element domain { STRING }* } masquerade_users = element masquerade_users { LIST, element masquerade_user { - element user { text } & - element address { text } & - element comment { text }? + element user { STRING } & + element address { STRING } & + element comment { STRING }? }* } @@ -87,7 +101,7 @@ ( "sendmail" | "postfix" ) } -outgoing_mail_server = element outgoing_mail_server { text } +outgoing_mail_server = element outgoing_mail_server { STRING } postfix_mda = element postfix_mda { @@ -96,10 +110,10 @@ } smtp_use_TLS = - element smtp_use_TLS { "yes" | "must" | "no" } + element smtp_use_TLS { STRING_ATTR, ("yes" | "must" | "no") } system_mail_sender = - element system_mail_sender { text } + element system_mail_sender { STRING } use_amavis = element use_amavis { BOOLEAN } use_dkim = element use_dkim { BOOLEAN } @@ -108,9 +122,9 @@ element virtual_users { LIST, element virtual_user { - element alias { text } & - element destinations { text } & - element comment { text }? + element alias { STRING } & + element destinations { STRING } & + element comment { STRING }? }* } @@ -118,9 +132,9 @@ element smtp_auth { LIST, element smtp_auth_entry { - element password { text } & - element server { text } & - element user { text } + element password { STRING } & + element server { STRING } & + element user { STRING } }* } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/test/data/aliases new/yast2-mail-4.3.0/test/data/aliases --- old/yast2-mail-4.2.2/test/data/aliases 1970-01-01 01:00:00.000000000 +0100 +++ new/yast2-mail-4.3.0/test/data/aliases 2020-05-12 15:29:02.000000000 +0200 @@ -0,0 +1,7 @@ +#baz +foo: bar +#kuk +root: leaf +#baz2 +foo2: bar2 +#trailing comment diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/test/data/empty new/yast2-mail-4.3.0/test/data/empty --- old/yast2-mail-4.2.2/test/data/empty 1970-01-01 01:00:00.000000000 +0100 +++ new/yast2-mail-4.3.0/test/data/empty 2020-05-12 15:29:02.000000000 +0200 @@ -0,0 +1 @@ +# Empty file (just a comment) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/test/mail_aliases_test.rb new/yast2-mail-4.3.0/test/mail_aliases_test.rb --- old/yast2-mail-4.2.2/test/mail_aliases_test.rb 1970-01-01 01:00:00.000000000 +0100 +++ new/yast2-mail-4.3.0/test/mail_aliases_test.rb 2020-05-12 15:29:02.000000000 +0200 @@ -0,0 +1,122 @@ +#!/usr/bin/env rspec +# Copyright (c) [2020] 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" + +Yast.import "MailTable" +Yast.import "MailAliases" + +describe Yast::MailAliases do + describe ".mergeTables" do + let(:old1) do + [ + { + "comment" => " Basic system aliases that MUST be present.\n", + "value" => "root", + "key" => "postmaster" + }, + { "comment" => "", "value" => "postmaster", "key" => "mailer-daemon" }, + { "comment" => " amavis\n", "value" => "root", "key" => "virusalert" }, + { + "comment" => " General redirections for pseudo accounts in /etc/passwd.\n", + "value" => "root", + "key" => "administrator" + }, + { "comment" => "", "value" => "root", "key" => "daemon" }, + { "comment" => "", "value" => "root", "key" => "nobody" }, + { + "comment" => " \"bin\" used to be in /etc/passwd\n", + "value" => "root", + "key" => "bin" + }, + { + "comment" => " Further well-known aliases for dns/news/ftp/mail/fax/web/gnats.\n", + "value" => "news", + "key" => "newsadm" + }, + { "comment" => "", "value" => "news", "key" => "newsadmin" }, + { "comment" => "", "value" => "news", "key" => "usenet" } + ] + end + + let(:new1) do + [ + { "key" => "root", "value" => "auser", "comment" => " I am r00t!" }, + { "key" => "B.User", "value" => "buser", "comment" => " blah" }, + { "key" => "usenet", "value" => "root", "comment" => " direct" }, + { "key" => "A.User", "value" => "auser", "comment" => "" }, + { "key" => "newsadmin", "value" => "root", "comment" => " direct" } + ] + end + + let(:merged) do + old1[0..7] + [ + { "comment" => " direct", "key" => "newsadmin", "value" => "root" }, + { "comment" => " direct", "key" => "usenet", "value" => "root" }, + { "comment" => " I am r00t!", "key" => "root", "value" => "auser" }, + { "comment" => " blah", "key" => "B.User", "value" => "buser" }, + { "comment" => "", "key" => "A.User", "value" => "auser" } + ] + end + + it "returns a merged table" do + expect(described_class.mergeTables(new1, old1)).to eq merged + end + + context "when the first table is empty" do + let(:new1) { [] } + + it "returns the second table" do + expect(described_class.mergeTables(new1, old1)).to eq old1 + end + end + + context "when the second table is empty" do + let(:old1) { [] } + + it "returns the first table" do + expect(described_class.mergeTables(new1, old1)).to eq new1 + end + end + + context "when both tables are empty" do + let(:old1) { [] } + let(:new1) { [] } + + it "returns an empty table" do + expect(described_class.mergeTables(new1, old1)).to eq [] + end + end + end + + # NOTE: + # This is a highly simplified version of the old rootalias.rb test. + # To be a real substitute we should test the effect of #SetRootAlias + # as well. + describe ".GetRootAlias" do + before do + Yast::MailTable.SetFileName("aliases", "#{DATA_PATH}/aliases") + end + + it "returns the value from the aliases file" do + expect(described_class.GetRootAlias).to eq "leaf" + end + end +end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/test/mail_test.rb new/yast2-mail-4.3.0/test/mail_test.rb --- old/yast2-mail-4.2.2/test/mail_test.rb 1970-01-01 01:00:00.000000000 +0100 +++ new/yast2-mail-4.3.0/test/mail_test.rb 2020-05-12 15:29:02.000000000 +0200 @@ -0,0 +1,186 @@ +#!/usr/bin/env rspec +# Copyright (c) [2020] 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" + +Yast.import "Progress" +Yast.import "Mail" +Yast.import "MailTable" + +describe Yast::Mail do + def expect_sysconfig_read(route, value) + expect(Yast::SCR).to receive(:Read).with(path(".sysconfig.#{route}")).and_return value + end + + def allow_read(route, value) + allow(Yast::SCR).to receive(:Read).with(path(route)).and_return value + end + + let(:must_abort) { proc { false } } + let(:firewalld) { double("Firewalld", read: true) } + + before do + allow(Yast::PackageSystem).to receive(:Installed) do |package| + package == mail_system + end + + Yast::MailTable.SetFileName("aliases", "#{DATA_PATH}/aliases") + allow(Yast::MailTable).to receive(:Read).and_call_original + + Yast::Progress.off + + allow(Y2Firewall::Firewalld).to receive(:instance).and_return firewalld + allow(Yast::Service).to receive(:Enabled).with("fetchmail").and_return false + + allow_read(".sysconfig.mail.MAIL_CREATE_CONFIG", "yes") + allow_read(".sysconfig.mail.SMTPD_LISTEN_REMOTE", "yes") + allow_read(".sysconfig.amavis.USE_AMAVIS", "no") + allow_read(".sysconfig.mail.FROM_HEADER", "foo.test") + allow_read(".mail.fetchmail.accounts", []) + + allow(Yast::SCR).to receive(:Execute).with(path(".target.bash_output"), "/usr/bin/id --user") + .and_return("stdout" => "0\n") + end + + context "when sendmail is installed" do + let(:mail_system) { "sendmail" } + + before do + Yast::MailTable.SetFileName("sendmail.generics", "#{DATA_PATH}/empty") + Yast::MailTable.SetFileName("sendmail.virtuser", "#{DATA_PATH}/empty") + end + + describe ".Read" do + it "reads the sendmail configuration" do + expect_sysconfig_read("sendmail.SENDMAIL_NOCANONIFY", "no") + expect_sysconfig_read("sendmail.SENDMAIL_EXPENSIVE", "no") + expect_sysconfig_read("sendmail.SENDMAIL_LOCALHOST", "") + expect_sysconfig_read("sendmail.SENDMAIL_SMARTHOST", "") + expect_sysconfig_read("sendmail.MASQUERADE_DOMAINS", "") + + expect(Yast::MailTable).to receive(:Read).with("sendmail.generics").and_call_original + expect(Yast::MailTable).to receive(:Read).with("sendmail.virtuser").and_call_original + + expect(Yast::SCR).to receive(:Read).with(path(".mail.sendmail.auth.accounts")) + .and_return("more" => 1, "password" => "p", "server" => "s", "user" => "u") + + expect_sysconfig_read("sendmail.SMTP_AUTH_MECHANISMS", "") + + described_class.Read(must_abort) + end + end + + describe ".Write" do + before do + # To make this work in the same way than the old testsuite, let's + # execute Read first (with all the needed mocks) + + allow_read(".sysconfig.sendmail.SENDMAIL_NOCANONIFY", "no") + allow_read(".sysconfig.sendmail.SENDMAIL_EXPENSIVE", "no") + allow_read(".sysconfig.sendmail.SENDMAIL_LOCALHOST", "") + allow_read(".sysconfig.sendmail.SENDMAIL_SMARTHOST", "") + allow_read(".sysconfig.sendmail.MASQUERADE_DOMAINS", "") + allow_read( + ".mail.sendmail.auth.accounts", + "more" => 1, "password" => "p", "server" => "s", "user" => "u" + ) + allow_read(".sysconfig.sendmail.SMTP_AUTH_MECHANISMS", "") + + described_class.Read(must_abort) + # Now we are ready to call Write with a known state + + # Let's mock now the calls executed by Write itself + allow(firewalld).to receive(:write_only) + allow_read(".sysconfig.sendmail.SENDMAIL_ARGS", "-L sendmail -Am -bd -q30m -om") + end + + def expect_write(route, value) + expect(Yast::SCR).to receive(:Write).with(path(route), value) + end + + it "writes the sendmail configuration and adjusts all running services" do + expect_write(".sysconfig.mail.MAIL_CREATE_CONFIG", "yes") + expect_write(".sysconfig.mail.SMTPD_LISTEN_REMOTE", "yes") + expect_write(".sysconfig.mail.FROM_HEADER", "foo.test") + expect_write(".sysconfig.mail", nil) + expect_write(".sysconfig.sendmail.SENDMAIL_NOCANONIFY", "no") + expect_write(".sysconfig.sendmail.SENDMAIL_EXPENSIVE", "no") + expect_write(".sysconfig.sendmail.SENDMAIL_LOCALHOST", "") + expect_write(".sysconfig.sendmail.SENDMAIL_SMARTHOST", "") + expect_write(".sysconfig.sendmail.MASQUERADE_DOMAINS", "") + expect_write(".sysconfig.sendmail", nil) + expect_write(".sysconfig.amavis.USE_AMAVIS", "no") + expect_write(".sysconfig.amavis.USE_DKIM", "no") + expect_write(".sysconfig.amavis", nil) + expect_write(".mail.sendmail.auth.accounts", nil) + expect_write(".mail.sendmail.auth", nil) + + expect(Yast::SCR).to receive(:Execute).with( + path(".target.bash"), + /test -e .*novell.postfix-check-mail-queue.* rm .*novell.postfix-check-mail-queue/ + ) + + expect(Yast::MailAliases).to receive(:WriteAliases).and_return true + expect(Yast::MailTable).to receive(:Write).with("sendmail.virtuser", anything) + expect(Yast::MailTable).to receive(:Write).with("sendmail.generics", anything) + + expect(Yast::Service).to receive(:Enable).with "sendmail" + expect(Yast::Service).to receive(:Adjust).with("amavis", anything).twice + expect(Yast::Service).to receive(:Adjust).with("freshclam", anything) + expect(Yast::Service).to receive(:Adjust).with("clamd", anything) + expect(Yast::Service).to receive(:Stop).with "amavis" + expect(Yast::Service).to receive(:Stop).with "fetchmail" + expect(Yast::Service).to receive(:Restart).with("sendmail").and_return true + expect(firewalld).to receive(:reload) + + described_class.Write(must_abort) + end + end + end + + context "when postfix is installed" do + let(:mail_system) { "postfix" } + + before do + Yast::MailTable.SetFileName("postfix.sendercanonical", "#{DATA_PATH}/empty") + Yast::MailTable.SetFileName("postfix.virtual", "#{DATA_PATH}/empty") + + allow(Yast::Service).to receive(:Enabled).with("postfix").and_return false + end + + it "reads the postfix configuration" do + expect_sysconfig_read("postfix.POSTFIX_NODNS", "no") + expect_sysconfig_read("postfix.POSTFIX_DIALUP", "no") + expect_sysconfig_read("postfix.POSTFIX_LOCALDOMAINS", "") + expect_sysconfig_read("postfix.POSTFIX_SMTP_TLS_CLIENT", "") + expect_sysconfig_read("postfix.POSTFIX_RELAYHOST", "") + expect_sysconfig_read("postfix.POSTFIX_MDA", "local") + expect_sysconfig_read("postfix.POSTFIX_MASQUERADE_DOMAIN", "") + + expect(Yast::MailTable).to receive(:Read).with("postfix.sendercanonical").and_call_original + expect(Yast::MailTable).to receive(:Read).with("postfix.virtual").and_call_original + + expect(Yast::SCR).to receive(:Read).with(path(".mail.postfix.auth.accounts")) + .and_return("more" => 1, "password" => "p", "server" => "s", "user" => "u") + + described_class.Read(must_abort) + end + end +end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/test/test_helper.rb new/yast2-mail-4.3.0/test/test_helper.rb --- old/yast2-mail-4.2.2/test/test_helper.rb 1970-01-01 01:00:00.000000000 +0100 +++ new/yast2-mail-4.3.0/test/test_helper.rb 2020-05-12 15:29:02.000000000 +0200 @@ -0,0 +1,49 @@ +# Copyright (c) [2020] 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. + +# Set the paths +SRC_PATH = File.expand_path("../src", __dir__) +DATA_PATH = File.expand_path("data", __dir__) +ENV["Y2DIR"] = SRC_PATH + +# make sure we run the tests in English locale +# (some tests check the output which is marked for translation) +ENV["LC_ALL"] = "en_US.UTF-8" + +require "yast" +require "yast/rspec" + +if ENV["COVERAGE"] + require "simplecov" + SimpleCov.start do + add_filter "/test/" + end + + # track all ruby files under src + SimpleCov.track_files("#{SRC_PATH}/**/*.rb") + + # use coveralls for on-line code coverage reporting at Travis CI + if ENV["TRAVIS"] + require "coveralls" + SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[ + SimpleCov::Formatter::HTMLFormatter, + Coveralls::SimpleCov::Formatter + ] + end +end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/testsuite/tests/aliases.out new/yast2-mail-4.3.0/testsuite/tests/aliases.out --- old/yast2-mail-4.2.2/testsuite/tests/aliases.out 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/testsuite/tests/aliases.out 1970-01-01 01:00:00.000000000 +0100 @@ -1,7 +0,0 @@ -#baz -foo: bar -#kuk -root: leaf -#baz2 -foo2: bar2 -#trailing comment diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/testsuite/tests/mergeTables.out new/yast2-mail-4.3.0/testsuite/tests/mergeTables.out --- old/yast2-mail-4.2.2/testsuite/tests/mergeTables.out 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/testsuite/tests/mergeTables.out 1970-01-01 01:00:00.000000000 +0100 @@ -1,4 +0,0 @@ -Return [] -Return [$["comment":" I am r00t!", "key":"root", "value":"auser"], $["comment":" blah", "key":"B.User", "value":"buser"], $["comment":" direct", "key":"usenet", "value":"root"], $["comment":"", "key":"A.User", "value":"auser"], $["comment":" direct", "key":"newsadmin", "value":"root"]] -Return [$["comment":" Basic system aliases that MUST be present.\n", "key":"postmaster", "value":"root"], $["comment":"", "key":"mailer-daemon", "value":"postmaster"], $["comment":" amavis\n", "key":"virusalert", "value":"root"], $["comment":" General redirections for pseudo accounts in /etc/passwd.\n", "key":"administrator", "value":"root"], $["comment":"", "key":"daemon", "value":"root"], $["comment":"", "key":"nobody", "value":"root"], $["comment":" \"bin\" used to be in /etc/passwd\n", "key":"bin", "value":"root"], $["comment":" Further well-known aliases for dns/news/ftp/mail/fax/web/gnats.\n", "key":"newsadm", "value":"news"], $["comment":"", "key":"newsadmin", "value":"news"], $["comment":"", "key":"usenet", "value":"news"]] -Return [$["comment":" Basic system aliases that MUST be present.\n", "key":"postmaster", "value":"root"], $["comment":"", "key":"mailer-daemon", "value":"postmaster"], $["comment":" amavis\n", "key":"virusalert", "value":"root"], $["comment":" General redirections for pseudo accounts in /etc/passwd.\n", "key":"administrator", "value":"root"], $["comment":"", "key":"daemon", "value":"root"], $["comment":"", "key":"nobody", "value":"root"], $["comment":" \"bin\" used to be in /etc/passwd\n", "key":"bin", "value":"root"], $["comment":" Further well-known aliases for dns/news/ftp/mail/fax/web/gnats.\n", "key":"newsadm", "value":"news"], $["comment":" direct", "key":"newsadmin", "value":"root"], $["comment":" direct", "key":"usenet", "value":"root"], $["comment":" I am r00t!", "key":"root", "value":"auser"], $["comment":" blah", "key":"B.User", "value":"buser"], $["comment":"", "key":"A.User", "value":"auser"]] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/testsuite/tests/mergeTables.rb new/yast2-mail-4.3.0/testsuite/tests/mergeTables.rb --- old/yast2-mail-4.2.2/testsuite/tests/mergeTables.rb 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/testsuite/tests/mergeTables.rb 1970-01-01 01:00:00.000000000 +0100 @@ -1,66 +0,0 @@ -# encoding: utf-8 - -# Module: -# Mail configuration -# -# Summary: -# Testsuite -# -# Authors: -# Martin Vidner <mvid...@suse.cz> -# -# $Id$ -module Yast - class MergeTablesClient < Client - def main - Yast.include self, "testsuite.rb" - TESTSUITE_INIT([{}, {}, {}], nil) - Yast.import "MailAliases" - - @old1 = [ - { - "comment" => " Basic system aliases that MUST be present.\n", - "value" => "root", - "key" => "postmaster" - }, - { "comment" => "", "value" => "postmaster", "key" => "mailer-daemon" }, - { "comment" => " amavis\n", "value" => "root", "key" => "virusalert" }, - { - "comment" => " General redirections for pseudo accounts in /etc/passwd.\n", - "value" => "root", - "key" => "administrator" - }, - { "comment" => "", "value" => "root", "key" => "daemon" }, - { "comment" => "", "value" => "root", "key" => "nobody" }, - { - "comment" => " \"bin\" used to be in /etc/passwd\n", - "value" => "root", - "key" => "bin" - }, - { - "comment" => " Further well-known aliases for dns/news/ftp/mail/fax/web/gnats.\n", - "value" => "news", - "key" => "newsadm" - }, - { "comment" => "", "value" => "news", "key" => "newsadmin" }, - { "comment" => "", "value" => "news", "key" => "usenet" } - ] - @new1 = [ - { "key" => "root", "value" => "auser", "comment" => " I am r00t!" }, - { "key" => "B.User", "value" => "buser", "comment" => " blah" }, - { "key" => "usenet", "value" => "root", "comment" => " direct" }, - { "key" => "A.User", "value" => "auser", "comment" => "" }, - { "key" => "newsadmin", "value" => "root", "comment" => " direct" } - ] - - TEST(lambda { MailAliases.mergeTables([], []) }, [], nil) - TEST(lambda { MailAliases.mergeTables(@new1, []) }, [], nil) - TEST(lambda { MailAliases.mergeTables([], @old1) }, [], nil) - TEST(lambda { MailAliases.mergeTables(@new1, @old1) }, [], nil) - - nil - end - end -end - -Yast::MergeTablesClient.new.main diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/testsuite/tests/readwrite.out new/yast2-mail-4.3.0/testsuite/tests/readwrite.out --- old/yast2-mail-4.2.2/testsuite/tests/readwrite.out 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/testsuite/tests/readwrite.out 1970-01-01 01:00:00.000000000 +0100 @@ -1,66 +0,0 @@ -Execute .target.bash "rpm -q --whatprovides sendmail" 0 -Read .sysconfig.mail.MAIL_CREATE_CONFIG "yes" -Read .sysconfig.mail.SMTPD_LISTEN_REMOTE "yes" -Execute .target.bash "rpm -q --whatprovides SuSEfirewall2" 0 -Read .init.scripts.exists "SuSEfirewall2_init" true -Read .init.scripts.runlevel "SuSEfirewall2_init" $["SuSEfirewall2_final":$["start":[]], "SuSEfirewall2_init":$["start":[]], "SuSEfirewall2_setup":$["start":[]], "amavis":$["start":["3", "5"], "stop":["3", "5"]], "fetchmail":$["start":["3", "5"], "stop":["3", "5"]], "postfix":$["start":["3", "5"], "stop":["3", "5"]], "sendmail":$["start":["3", "5"], "stop":["3", "5"]]] -Read .init.scripts.exists "SuSEfirewall2_init" true -Execute .target.bash "/etc/init.d/SuSEfirewall2_init status" $["TERM":"raw"] 0 -Read .sysconfig.sendmail.SENDMAIL_NOCANONIFY "no" -Read .sysconfig.sendmail.SENDMAIL_EXPENSIVE "no" -Execute .target.bash "rpm -q --whatprovides amavisd-new" 0 -Read .sysconfig.amavis.USE_AMAVIS "yes" -Read .sysconfig.sendmail.SENDMAIL_LOCALHOST "" -Read .sysconfig.sendmail.SENDMAIL_SMARTHOST "" -Read .sysconfig.mail.FROM_HEADER "foo.test" -Read .sysconfig.sendmail.MASQUERADE_DOMAINS "" -Execute .target.bash_output "/usr/bin/id --user" $["exit":0, "stderr":"", "stdout":""] -Read .mail.fetchmail.accounts [] -Read .mail.sendmail.auth.accounts [$["more":1, "password":"p", "server":"s", "user":"u"]] -Read .sysconfig.sendmail.SMTP_AUTH_MECHANISMS "" -Return true -Write .sysconfig.mail.MAIL_CREATE_CONFIG "yes" true -Write .sysconfig.mail.SMTPD_LISTEN_REMOTE "yes" true -Write .sysconfig.sendmail.SENDMAIL_NOCANONIFY "no" true -Write .sysconfig.sendmail.SENDMAIL_EXPENSIVE "no" true -Read .init.scripts.exists "sendmail" true -Read .init.scripts.exists "sendmail" true -Read .init.scripts.exists "sendmail" true -Read .init.scripts.runlevel "sendmail" $["SuSEfirewall2_final":$["start":[]], "SuSEfirewall2_init":$["start":[]], "SuSEfirewall2_setup":$["start":[]], "amavis":$["start":["3", "5"], "stop":["3", "5"]], "fetchmail":$["start":["3", "5"], "stop":["3", "5"]], "postfix":$["start":["3", "5"], "stop":["3", "5"]], "sendmail":$["start":["3", "5"], "stop":["3", "5"]]] -Read .init.scripts.comment "sendmail" $["amavis":$[], "fetchmail":$[], "postfix":$[], "sendmail":$[]] -Write .sysconfig.amavis.USE_AMAVIS "yes" true -Read .init.scripts.exists "amavis" true -Read .init.scripts.exists "amavis" true -Read .init.scripts.runlevel "amavis" $["SuSEfirewall2_final":$["start":[]], "SuSEfirewall2_init":$["start":[]], "SuSEfirewall2_setup":$["start":[]], "amavis":$["start":["3", "5"], "stop":["3", "5"]], "fetchmail":$["start":["3", "5"], "stop":["3", "5"]], "postfix":$["start":["3", "5"], "stop":["3", "5"]], "sendmail":$["start":["3", "5"], "stop":["3", "5"]]] -Read .init.scripts.comment "amavis" $["amavis":$[], "fetchmail":$[], "postfix":$[], "sendmail":$[]] -Read .sysconfig.sendmail.SENDMAIL_ARGS "-L sendmail -Am -bd -q30m -om" -Write .sysconfig.sendmail.SENDMAIL_LOCALHOST "" true -Write .sysconfig.sendmail.SENDMAIL_SMARTHOST "" true -Write .sysconfig.mail.FROM_HEADER "foo.test" true -Write .sysconfig.sendmail.MASQUERADE_DOMAINS "" true -Write .mail.fetchmail.accounts [] true -Write .mail.fetchmail nil true -Read .init.scripts.exists "fetchmail" true -Read .init.scripts.exists "fetchmail" true -Read .init.scripts.exists "fetchmail" true -Read .init.scripts.runlevel "fetchmail" $["SuSEfirewall2_final":$["start":[]], "SuSEfirewall2_init":$["start":[]], "SuSEfirewall2_setup":$["start":[]], "amavis":$["start":["3", "5"], "stop":["3", "5"]], "fetchmail":$["start":["3", "5"], "stop":["3", "5"]], "postfix":$["start":["3", "5"], "stop":["3", "5"]], "sendmail":$["start":["3", "5"], "stop":["3", "5"]]] -Read .init.scripts.comment "fetchmail" $["amavis":$[], "fetchmail":$[], "postfix":$[], "sendmail":$[]] -Execute .target.bash_output "/sbin/insserv -r /etc/init.d/fetchmail" $["exit":0, "stderr":"", "stdout":""] -Write .mail.sendmail.auth.accounts [$["more":1, "password":"p", "server":"s", "user":"u"]] true -Write .sysconfig.sendmail.SMTP_AUTH_MECHANISMS "plain gssapi digest-md5 cram-md5" true -Write .mail.sendmail.auth nil true -Write .sysconfig.amavis nil true -Write .sysconfig.mail nil true -Write .sysconfig.sendmail nil true -Execute .target.bash "/sbin/SuSEconfig --module sendmail" 0 -Read .init.scripts.exists "amavis" true -Execute .target.bash "/etc/init.d/amavis stop" $["TERM":"raw"] 0 -Read .init.scripts.exists "amavis" true -Execute .target.bash "/etc/init.d/amavis start" $["TERM":"raw"] 0 -Read .init.scripts.exists "fetchmail" true -Execute .target.bash "/etc/init.d/fetchmail stop" $["TERM":"raw"] 0 -Read .init.scripts.exists "sendmail" true -Execute .target.bash "/etc/init.d/sendmail restart" $["TERM":"raw"] 0 -Read .init.scripts.exists "SuSEfirewall2_init" true -Execute .target.bash "/etc/init.d/SuSEfirewall2_init status" $["TERM":"raw"] 0 -Return true diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/testsuite/tests/readwrite.rb new/yast2-mail-4.3.0/testsuite/tests/readwrite.rb --- old/yast2-mail-4.2.2/testsuite/tests/readwrite.rb 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/testsuite/tests/readwrite.rb 1970-01-01 01:00:00.000000000 +0100 @@ -1,176 +0,0 @@ -# encoding: utf-8 - -# Module: -# Mail configuration -# Summary: -# Testsuite -# Authors: -# Martin Vidner <mvid...@suse.cz> -# -# $Id$ -module Yast - class ReadwriteClient < Client - def main - # testedfiles: Mail.ycp MailTable.pm MailTableInclude.pm Package.ycp PackageSystem.ycp Report.ycp Require.ycp Service.ycp Testsuite.ycp - - Yast.include self, "testsuite.rb" - - @READ = { - # Runlevel: - "init" => { - "scripts" => { - "exists" => true, - "runlevel" => { - "sendmail" => { - "start" => ["3", "5"], - "stop" => ["3", "5"] - }, - "postfix" => { - "start" => ["3", "5"], - "stop" => ["3", "5"] - }, - "amavis" => { - "start" => ["3", "5"], - "stop" => ["3", "5"] - }, - "fetchmail" => { - "start" => ["3", "5"], - "stop" => ["3", "5"] - }, - "SuSEfirewall2_init" => { "start" => [] }, - "SuSEfirewall2_setup" => { "start" => [] }, - "SuSEfirewall2_final" => { "start" => [] } - }, - # their contents is not important for ServiceAdjust - "comment" => { - "sendmail" => {}, - "postfix" => {}, - "amavis" => {}, - "fetchmail" => {} - } - } - }, - # Mail itself: - "sysconfig" => { - "mail" => { - "MAIL_CREATE_CONFIG" => "yes", - "SMTPD_LISTEN_REMOTE" => "yes", - "FROM_HEADER" => "foo.test" - }, - "amavis" => { "USE_AMAVIS" => "yes" }, - "sendmail" => { - "SENDMAIL_NOCANONIFY" => "no", - "SENDMAIL_EXPENSIVE" => "no", - "SENDMAIL_LOCALHOST" => "", - "SENDMAIL_SMARTHOST" => "", - "MASQUERADE_DOMAINS" => "", - # TODO: check for a new default in the installed system? - # (evade the dummy agent, neededforbuild sendmail) - "SENDMAIL_ARGS" => "-L sendmail -Am -bd -q30m -om", - "SMTP_AUTH_MECHANISMS" => "" - } - }, - "mail" => { - "sendmail" => { - "generics" => { "table" => [] }, - "virtuser" => { "table" => [] }, - "auth" => { - "accounts" => [ - { - "server" => "s", - "user" => "u", - "password" => "p", - "more" => 1 - } - ] - } - }, - "aliases" => { "table" => [] }, - "fetchmail" => { "accounts" => [] } - } - } - - @WRITE = {} - - @EXECUTE_0 = { - "target" => { - "bash" => 0, - "bash_output" => { "exit" => 0, "stdout" => "", "stderr" => "" } - } - } - - @EXECUTE_1 = { - "target" => { - "bash" => 1, - "bash_output" => { "exit" => 0, "stdout" => "", "stderr" => "" } - } - } - - @EXECUTE_INIT = { - "target" => { - "bash" => 1, - "bash_output" => { - "exit" => 0, - "stderr" => "", - "stdout" => "charmap=\"UTF-8\"\n" - } - } - } - - @READ_INIT = { - "console" => { "CONSOLE_ENCODING" => "en_US.UTF-8" }, - "target" => { "size" => 1 } - } - - # added testsuite init, because of firewall - TESTSUITE_INIT([@READ_INIT, {}, @EXECUTE_INIT], nil) - - Yast.import "Progress" - Yast.import "Mail" - Yast.import "MailTable" - - MailTable.SetFileName("aliases", "tests/aliases.out") - MailTable.SetFileName("sendmail.generics", "tests/generics.out") - MailTable.SetFileName("sendmail.virtuser", "tests/virtuser.out") - - - # Pkg::FAKE (`IsProvided, $["sendmail": true, "amavis-sendmail": true, - # "amavis-postfix": false]); - - @dont_abort = lambda { false } - Progress.off - TEST( - lambda { Mail.Read(@dont_abort) }, - [ - @READ, - @WRITE, #rpm amavisd-new - [ - @EXECUTE_0, #rpm sendmail - @EXECUTE_0 - ] - ], - nil - ) - Mail.write_only = false - TEST( - lambda { Mail.Write(@dont_abort) }, - [ - @READ, - @WRITE, #sendmail restart - [ - #EXECUTE_1, //rpm amavis-postfix - @EXECUTE_0, #SuSEconfig - @EXECUTE_0, #amavis stop - @EXECUTE_0, #amavis start - @EXECUTE_0 - ] - ], - nil - ) - - nil - end - end -end - -Yast::ReadwriteClient.new.main diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/testsuite/tests/rootalias.out new/yast2-mail-4.3.0/testsuite/tests/rootalias.out --- old/yast2-mail-4.2.2/testsuite/tests/rootalias.out 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/testsuite/tests/rootalias.out 1970-01-01 01:00:00.000000000 +0100 @@ -1,8 +0,0 @@ -Dump sendmail -Return leaf -Return true -Return true -Dump postfix -Return -Return true -Return true diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-mail-4.2.2/testsuite/tests/rootalias.rb new/yast2-mail-4.3.0/testsuite/tests/rootalias.rb --- old/yast2-mail-4.2.2/testsuite/tests/rootalias.rb 2019-08-27 19:39:17.000000000 +0200 +++ new/yast2-mail-4.3.0/testsuite/tests/rootalias.rb 1970-01-01 01:00:00.000000000 +0100 @@ -1,69 +0,0 @@ -# encoding: utf-8 - -# Module: -# NIS client configuration -# -# Summary: -# Testsuite -# -# Authors: -# Martin Vidner <mvid...@suse.cz> -# -# $Id$ -module Yast - class RootaliasClient < Client - def main - Yast.include self, "testsuite.rb" - TESTSUITE_INIT([{}, {}, {}], nil) - Yast.import "MailTable" - Yast.import "MailAliases" - - MailTable.SetFileName("aliases", "tests/aliases.out") - - # the test data is a bit convoluted because formerly - # the data was read from .mail.{sendmail,postfix}.aliases.table - - @READ_s = { - # targetpkg: - "targetpkg" => { - # sendmail - "installed" => true - } - } - - @READ_p1 = { - # targetpkg: - "targetpkg" => { - # sendmail - "installed" => false - } - } - - @READ_p2 = { - # targetpkg: - "targetpkg" => { - # postfix - "installed" => true - } - } - - @WRITE = {} - - DUMP("sendmail") - TEST(lambda { MailAliases.GetRootAlias }, [@READ_s], nil) - TEST(lambda { MailAliases.SetRootAlias("ruut") }, [@READ_s], nil) - TEST(lambda { MailAliases.SetRootAlias("") }, [@READ_s], nil) - - DUMP("postfix") - TEST(lambda { MailAliases.GetRootAlias }, [[@READ_p1, @READ_p2]], nil) - # apparently the dumb^H^H^H^Hdummy aggent reads from the first map - # while there's input. - TEST(lambda { MailAliases.SetRootAlias("ruut") }, [[@READ_p1, @READ_p2]], nil) - TEST(lambda { MailAliases.SetRootAlias("") }, [[@READ_p1, @READ_p2]], nil) - - nil - end - end -end - -Yast::RootaliasClient.new.main