Hello community, here is the log from the commit of package yast2-update for openSUSE:Factory checked in at 2017-04-25 08:56:23 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/yast2-update (Old) and /work/SRC/openSUSE:Factory/.yast2-update.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-update" Tue Apr 25 08:56:23 2017 rev:114 rq:489346 version:3.2.2 Changes: -------- --- /work/SRC/openSUSE:Factory/yast2-update/yast2-update.changes 2017-01-10 10:34:18.572965294 +0100 +++ /work/SRC/openSUSE:Factory/.yast2-update.new/yast2-update.changes 2017-04-25 08:56:24.782150249 +0200 @@ -1,0 +2,13 @@ +Wed Apr 19 14:38:34 UTC 2017 - [email protected] + +- Fixed parsing whitespace lines in the original /etc/fstab + (bsc#1030425) +- 3.2.2 + +------------------------------------------------------------------- +Mon Jan 30 12:07:55 UTC 2017 - [email protected] + +- Allow YaST modules to add packages during upgrade (bsc#1009834) +- 3.2.1 + +------------------------------------------------------------------- Old: ---- yast2-update-3.2.0.tar.bz2 New: ---- yast2-update-3.2.2.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2-update.spec ++++++ --- /var/tmp/diff_new_pack.vYOTL5/_old 2017-04-25 08:56:25.354069379 +0200 +++ /var/tmp/diff_new_pack.vYOTL5/_new 2017-04-25 08:56:25.358068813 +0200 @@ -17,7 +17,7 @@ Name: yast2-update -Version: 3.2.0 +Version: 3.2.2 Release: 0 BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -26,8 +26,9 @@ BuildRequires: update-desktop-files BuildRequires: yast2 >= 3.1.126 BuildRequires: yast2-devtools >= 3.1.15 -BuildRequires: yast2-packager BuildRequires: yast2-ruby-bindings >= 1.0.0 +# Packages#proposal_for_update +BuildRequires: yast2-packager >= 3.2.13 # xmllint BuildRequires: libxml2-tools @@ -45,8 +46,8 @@ Requires: yast2 >= 3.1.126 Requires: yast2-installation -# packager/product_patterns.rb -Requires: yast2-packager >= 3.1.95 +# Packages#proposal_for_update +Requires: yast2-packager >= 3.2.13 # Pkg.TargetInitializeOptions() Requires: yast2-pkg-bindings >= 3.1.14 ++++++ yast2-update-3.2.0.tar.bz2 -> yast2-update-3.2.2.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.2.0/.travis.yml new/yast2-update-3.2.2/.travis.yml --- old/yast2-update-3.2.0/.travis.yml 2017-01-05 15:50:54.009550784 +0100 +++ new/yast2-update-3.2.2/.travis.yml 2017-04-19 17:30:54.849245123 +0200 @@ -1,16 +1,11 @@ -language: cpp -compiler: - - gcc +sudo: required +language: bash +services: + - docker + before_install: - # disable rvm, use system Ruby - - rvm reset - - wget https://raw.githubusercontent.com/yast/yast-devtools/master/travis-tools/travis_setup.sh - - sh ./travis_setup.sh -p "rake yast2-devtools yast2-testsuite yast2 yast2-packager yast2-installation-control" -g "rspec:3.3.0 yast-rake gettext" + - docker build -t yast-update-image . script: - - rake check:syntax - - rake check:pot - - make -f Makefile.cvs - - make - - sudo make install - - make check - + # 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 -e TRAVIS=1 -e TRAVIS_JOB_ID="$TRAVIS_JOB_ID" yast-update-image yast-travis-ruby diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.2.0/Dockerfile new/yast2-update-3.2.2/Dockerfile --- old/yast2-update-3.2.0/Dockerfile 1970-01-01 01:00:00.000000000 +0100 +++ new/yast2-update-3.2.2/Dockerfile 2017-04-19 17:30:54.865245123 +0200 @@ -0,0 +1,3 @@ +FROM yastdevel/ruby +COPY . /usr/src/app + diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.2.0/package/yast2-update.changes new/yast2-update-3.2.2/package/yast2-update.changes --- old/yast2-update-3.2.0/package/yast2-update.changes 2017-01-05 15:50:54.105550784 +0100 +++ new/yast2-update-3.2.2/package/yast2-update.changes 2017-04-19 17:30:54.897245123 +0200 @@ -1,4 +1,17 @@ ------------------------------------------------------------------- +Wed Apr 19 14:38:34 UTC 2017 - [email protected] + +- Fixed parsing whitespace lines in the original /etc/fstab + (bsc#1030425) +- 3.2.2 + +------------------------------------------------------------------- +Mon Jan 30 12:07:55 UTC 2017 - [email protected] + +- Allow YaST modules to add packages during upgrade (bsc#1009834) +- 3.2.1 + +------------------------------------------------------------------- Thu Jan 5 14:43:00 UTC 2017 - [email protected] - Add storage to build dependencies as tests depends on it diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.2.0/package/yast2-update.spec new/yast2-update-3.2.2/package/yast2-update.spec --- old/yast2-update-3.2.0/package/yast2-update.spec 2017-01-05 15:50:54.105550784 +0100 +++ new/yast2-update-3.2.2/package/yast2-update.spec 2017-04-19 17:30:54.901245123 +0200 @@ -17,7 +17,7 @@ Name: yast2-update -Version: 3.2.0 +Version: 3.2.2 Release: 0 BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -29,7 +29,8 @@ BuildRequires: yast2-devtools >= 3.1.15 BuildRequires: yast2-ruby-bindings >= 1.0.0 BuildRequires: yast2 >= 3.1.126 -BuildRequires: yast2-packager +# Packages#proposal_for_update +BuildRequires: yast2-packager >= 3.2.13 # xmllint BuildRequires: libxml2-tools @@ -47,8 +48,8 @@ Requires: yast2 >= 3.1.126 Requires: yast2-installation -# packager/product_patterns.rb -Requires: yast2-packager >= 3.1.95 +# Packages#proposal_for_update +Requires: yast2-packager >= 3.2.13 # Pkg.TargetInitializeOptions() Requires: yast2-pkg-bindings >= 3.1.14 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.2.0/src/clients/packages_proposal.rb new/yast2-update-3.2.2/src/clients/packages_proposal.rb --- old/yast2-update-3.2.0/src/clients/packages_proposal.rb 2017-01-05 15:50:54.233550784 +0100 +++ new/yast2-update-3.2.2/src/clients/packages_proposal.rb 2017-04-19 17:30:54.925245123 +0200 @@ -40,6 +40,7 @@ Yast.import "Packages" Yast.import "SpaceCalculation" Yast.import "PackagesUI" + Yast.import "Packages" Yast.import "Update" @@ -62,6 +63,9 @@ # SpaceCalculation::ShowPartitionWarning (); @warning = SpaceCalculation.GetPartitionWarning + # Make an update proposal + Packages.proposal_for_update + # Count statistics --> # Pkg::GetPackages() # `installed all installed packages @@ -145,26 +149,33 @@ ) ) + @ret = { + "preformatted_proposal" => HTML.List(@tmp), + "trigger" => { + "expect" => { + "class" => "Yast::Packages", + "method" => "PackagesProposalChanged" + }, + "value" => false + } + } + if Ops.greater_than(Update.solve_errors, 0) # the proposal for the packages requires manual invervention - @ret = { - "preformatted_proposal" => HTML.List(@tmp), + @ret.merge!({ "links" => [PACKAGER_LINK], # TRANSLATORS: warning text, keep the HTML tags (<a href...>) untouched "warning" => _( "Cannot solve all conflicts. <a href=\"%s\">Manual intervention is required.</a>" ) % PACKAGER_LINK, "warning_level" => :blocker - } + }) elsif Ops.greater_than(Builtins.size(@warning), 0) # the proposal for the packages requires manual intervention - @ret = { - "preformatted_proposal" => HTML.List(@tmp), + @ret.merge!({ "warning" => Builtins.mergestring(@warning, "<br>"), "warning_level" => :warning - } - else - @ret = { "preformatted_proposal" => HTML.List(@tmp) } + }) end Builtins.y2milestone( diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.2.0/src/modules/RootPart.rb new/yast2-update-3.2.2/src/modules/RootPart.rb --- old/yast2-update-3.2.0/src/modules/RootPart.rb 2017-01-05 15:50:54.257550784 +0100 +++ new/yast2-update-3.2.2/src/modules/RootPart.rb 2017-04-19 17:30:54.937245123 +0200 @@ -809,6 +809,8 @@ fstab_file = Ops.add(Installation.destdir, "/etc/fstab") if FileUtils.Exists(fstab_file) + # Note: this is a copy from etc_fstab.scr file (yast2.rpm), + # keep the files in sync! SCR.RegisterAgent( path(".target.etc.fstab"), term( @@ -816,7 +818,8 @@ term( :Description, term(:File, fstab_file), - "#\n", # Comment + # tab and space is a workaround for white space only lines (bsc#1030425) + "#\n\t ", # Comment false, # read-only term( :List, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.2.0/test/Makefile.am new/yast2-update-3.2.2/test/Makefile.am --- old/yast2-update-3.2.0/test/Makefile.am 2017-01-05 15:50:54.289550784 +0100 +++ new/yast2-update-3.2.2/test/Makefile.am 2017-04-19 17:30:54.945245123 +0200 @@ -2,6 +2,7 @@ root_part_test.rb \ suse_release_test.rb \ inst_update_partition_auto_test.rb \ + packages_proposal_test.rb \ update_test.rb TEST_EXTENSIONS = .rb diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-update-3.2.0/test/packages_proposal_test.rb new/yast2-update-3.2.2/test/packages_proposal_test.rb --- old/yast2-update-3.2.0/test/packages_proposal_test.rb 1970-01-01 01:00:00.000000000 +0100 +++ new/yast2-update-3.2.2/test/packages_proposal_test.rb 2017-04-19 17:30:54.957245123 +0200 @@ -0,0 +1,57 @@ +#!/usr/bin/env rspec + +require_relative "test_helper" +require_relative "../src/clients/packages_proposal" + +describe Yast::PackagesProposalClient do + subject(:client) { described_class.new } + + before do + allow(Yast::WFM).to receive(:Args) do |n| + n.nil? ? args : args[n] + end + end + + describe "#main" do + context "when action is MakeProposal" do + let(:args) { ["MakeProposal"] } + + PACKAGES = { + installed: ["grub", "elilo"], + selected: ["grub", "grub2-efi", "grub2-pc"], + removed: ["elilo"] + } + + before do + allow(Yast::SpaceCalculation).to receive(:GetPartitionWarning) + .and_return(nil) + allow(Yast::Packages).to receive(:proposal_for_update) + allow(Yast::Pkg).to receive(:GetPackages).with(anything, true) do |status, _names_only| + PACKAGES[status] + end + end + + it "asks for a packages selection proposal" do + expect(Yast::Packages).to receive(:proposal_for_update) + client.main + end + + it "summarizes packages to update/install/remove" do + expect(Yast::Update).to receive(:packages_to_update=) + .with(1) + expect(Yast::Update).to receive(:packages_to_install=) + .with(2) + expect(Yast::Update).to receive(:packages_to_remove=) + .with(1) + client.main + end + + it "is meant to be triggered if packages proposal changes" do + expect(client.main["trigger"]).to eq({ + "expect" => { "class" => "Yast::Packages", "method" => "PackagesProposalChanged" }, + "value" => false + }) + end + end + end +end
