[DRE-commits] [chef] 05/07: Refresh patches again
Antonio Terceiro
terceiro at moszumanska.debian.org
Sun Jun 5 15:26:41 UTC 2016
This is an automated email from the git hooks/post-receive script.
terceiro pushed a commit to branch patch-queue/master
in repository chef.
commit 9bf5d5a4b8e8fa89f96e26b2d1d2cc091527f71a
Author: Antonio Terceiro <terceiro at debian.org>
Date: Sun Jun 5 12:05:01 2016 -0300
Refresh patches again
---
debian/patches/0001-Update-gemspec-file.patch | 17 ++---
.../0002-spec-remove-absolute-require-path.patch | 87 ++++++++++++++++++++--
...Make-specs-work-against-installed-package.patch | 80 --------------------
debian/patches/series | 1 -
4 files changed, 86 insertions(+), 99 deletions(-)
diff --git a/debian/patches/0001-Update-gemspec-file.patch b/debian/patches/0001-Update-gemspec-file.patch
index aa3ae7d..dc22e77 100644
--- a/debian/patches/0001-Update-gemspec-file.patch
+++ b/debian/patches/0001-Update-gemspec-file.patch
@@ -2,23 +2,16 @@ From: Lucas Kanashiro <kanashiro.duarte at gmail.com>
Date: Sat, 4 Jun 2016 13:17:06 -0300
Subject: Update gemspec file
-Remove rspec-junit-formatter dependency and flex plist version
-requirement
+- remove rspec-junit-formatter dependency
---
- chef.gemspec | 3 +--
- 1 file changed, 1 insertion(+), 2 deletions(-)
+ chef.gemspec | 1 -
+ 1 file changed, 1 deletion(-)
diff --git a/chef.gemspec b/chef.gemspec
-index b88c899..73fe36a 100644
+index 59367b0..6bd3d35 100644
--- a/chef.gemspec
+++ b/chef.gemspec
-@@ -33,12 +33,11 @@ Gem::Specification.new do |s|
-
- s.add_dependency "chef-zero", "~> 4.5"
-
-- s.add_dependency "plist", "~> 3.2"
-+ s.add_dependency "plist", ">= 3.2"
- s.add_dependency "iniparse", "~> 1.4"
+@@ -37,7 +37,6 @@ Gem::Specification.new do |s|
# Audit mode requires these, so they are non-developmental dependencies now
%w{rspec-core rspec-expectations rspec-mocks}.each { |gem| s.add_dependency gem, "~> 3.4" }
diff --git a/debian/patches/0002-spec-remove-absolute-require-path.patch b/debian/patches/0002-spec-remove-absolute-require-path.patch
index 9557633..e5f4d1f 100644
--- a/debian/patches/0002-spec-remove-absolute-require-path.patch
+++ b/debian/patches/0002-spec-remove-absolute-require-path.patch
@@ -2,15 +2,55 @@ From: Antonio Terceiro <terceiro at debian.org>
Date: Sat, 4 Jun 2016 13:47:47 -0300
Subject: spec: remove absolute require path
-This is not necessary; we should just trust the testing framework to
-setup the $LOAD_PATH
+All of those are not really necessary; we should just trust the testing
+framework to setup the $LOAD_PATH. This also makes the specs work
+against the installed package (as opposed to only working against a
+source checkout).
---
- spec/unit/chef_fs/config_spec.rb | 2 +-
- spec/unit/chef_fs/data_handler/group_handler_spec.rb | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
+ spec/spec_helper.rb | 13 +++----------
+ spec/unit/chef_fs/config_spec.rb | 2 +-
+ spec/unit/chef_fs/data_handler/group_handler_spec.rb | 2 +-
+ spec/unit/file_access_control_spec.rb | 2 +-
+ spec/unit/mixin/securable_spec.rb | 4 ++--
+ 5 files changed, 8 insertions(+), 15 deletions(-)
+diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
+index 2f6747c..5eb22c0 100644
+--- a/spec/spec_helper.rb
++++ b/spec/spec_helper.rb
+@@ -24,16 +24,9 @@ module Shell
+ IRB = nil unless defined? IRB
+ end
+
+-# Ruby 1.9 Compat
+-$:.unshift File.expand_path("../..", __FILE__)
+-
+ require "rubygems"
+ require "rspec/mocks"
+
+-$:.unshift(File.join(File.dirname(__FILE__), "..", "lib"))
+-$:.unshift(File.expand_path("../lib", __FILE__))
+-$:.unshift(File.dirname(__FILE__))
+-
+ if ENV["COVERAGE"]
+ require "simplecov"
+ SimpleCov.start do
+@@ -48,10 +41,10 @@ end
+ require "chef"
+ require "chef/knife"
+
+-Dir["lib/chef/knife/**/*.rb"].
+- map { |f| f.gsub("lib/", "") }.
++Gem.find_files('chef/knife/**/*.rb').
++ map { |f| f.gsub(%r{.*/chef/knife/}, "chef/knife/") }.
+ map { |f| f.gsub(%r{\.rb$}, "") }.
+- each { |f| require f }
++ each { |f| puts f; require f }
+
+ require "chef/resource_resolver"
+ require "chef/provider_resolver"
diff --git a/spec/unit/chef_fs/config_spec.rb b/spec/unit/chef_fs/config_spec.rb
-index 0adcbbf..bda4b1c 100644
+index 5fc5ad5..57a25ec 100644
--- a/spec/unit/chef_fs/config_spec.rb
+++ b/spec/unit/chef_fs/config_spec.rb
@@ -18,7 +18,7 @@
@@ -35,3 +75,38 @@ index 849bc84..2fd4a02 100644
class TestEntry < Mash
attr_accessor :name, :org
+diff --git a/spec/unit/file_access_control_spec.rb b/spec/unit/file_access_control_spec.rb
+index 4357a91..1b4017d 100644
+--- a/spec/unit/file_access_control_spec.rb
++++ b/spec/unit/file_access_control_spec.rb
+@@ -26,7 +26,7 @@ describe Chef::FileAccessControl do
+ # we have to re-load the file so the proper
+ # platform specific module is mixed in
+ @node = Chef::Node.new
+- load File.join(File.dirname(__FILE__), "..", "..", "lib", "chef", "file_access_control.rb")
++ load Gem.find_files("chef/file_access_control.rb").first
+ @resource = Chef::Resource::File.new("/tmp/a_file.txt")
+ @resource.owner("toor")
+ @resource.group("wheel")
+diff --git a/spec/unit/mixin/securable_spec.rb b/spec/unit/mixin/securable_spec.rb
+index 6f50ce8..19cecf3 100644
+--- a/spec/unit/mixin/securable_spec.rb
++++ b/spec/unit/mixin/securable_spec.rb
+@@ -46,7 +46,7 @@ describe Chef::Mixin::Securable do
+ describe "unix-specific behavior" do
+ before(:each) do
+ platform_mock :unix do
+- load File.join(File.dirname(__FILE__), "..", "..", "..", "lib", "chef", "mixin", "securable.rb")
++ load Gem.find_files("chef/mixin/securable.rb").first
+ @securable = Object.new
+ @securable.send(:extend, Chef::Mixin::Securable)
+ @securable.send(:extend, Chef::Mixin::ParamsValidate)
+@@ -177,7 +177,7 @@ describe Chef::Mixin::Securable do
+ describe "windows-specific behavior" do
+ before(:each) do
+ platform_mock :windows do
+- load File.join(File.dirname(__FILE__), "..", "..", "..", "lib", "chef", "mixin", "securable.rb")
++ load Gem.find_files("chef/mixin/securable.rb").first
+ securable_class = Class.new do
+ include Chef::Mixin::Securable
+ include Chef::Mixin::ParamsValidate
diff --git a/debian/patches/0003-Make-specs-work-against-installed-package.patch b/debian/patches/0003-Make-specs-work-against-installed-package.patch
deleted file mode 100644
index f7dd95c..0000000
--- a/debian/patches/0003-Make-specs-work-against-installed-package.patch
+++ /dev/null
@@ -1,80 +0,0 @@
-From: Antonio Terceiro <terceiro at debian.org>
-Date: Sat, 4 Jun 2016 23:42:22 -0300
-Subject: Make specs work against installed package
-
----
- spec/spec_helper.rb | 13 +++----------
- spec/unit/file_access_control_spec.rb | 2 +-
- spec/unit/mixin/securable_spec.rb | 4 ++--
- 3 files changed, 6 insertions(+), 13 deletions(-)
-
-diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
-index 2f6747c..5eb22c0 100644
---- a/spec/spec_helper.rb
-+++ b/spec/spec_helper.rb
-@@ -24,16 +24,9 @@ module Shell
- IRB = nil unless defined? IRB
- end
-
--# Ruby 1.9 Compat
--$:.unshift File.expand_path("../..", __FILE__)
--
- require "rubygems"
- require "rspec/mocks"
-
--$:.unshift(File.join(File.dirname(__FILE__), "..", "lib"))
--$:.unshift(File.expand_path("../lib", __FILE__))
--$:.unshift(File.dirname(__FILE__))
--
- if ENV["COVERAGE"]
- require "simplecov"
- SimpleCov.start do
-@@ -48,10 +41,10 @@ end
- require "chef"
- require "chef/knife"
-
--Dir["lib/chef/knife/**/*.rb"].
-- map { |f| f.gsub("lib/", "") }.
-+Gem.find_files('chef/knife/**/*.rb').
-+ map { |f| f.gsub(%r{.*/chef/knife/}, "chef/knife/") }.
- map { |f| f.gsub(%r{\.rb$}, "") }.
-- each { |f| require f }
-+ each { |f| puts f; require f }
-
- require "chef/resource_resolver"
- require "chef/provider_resolver"
-diff --git a/spec/unit/file_access_control_spec.rb b/spec/unit/file_access_control_spec.rb
-index 4357a91..1b4017d 100644
---- a/spec/unit/file_access_control_spec.rb
-+++ b/spec/unit/file_access_control_spec.rb
-@@ -26,7 +26,7 @@ describe Chef::FileAccessControl do
- # we have to re-load the file so the proper
- # platform specific module is mixed in
- @node = Chef::Node.new
-- load File.join(File.dirname(__FILE__), "..", "..", "lib", "chef", "file_access_control.rb")
-+ load Gem.find_files("chef/file_access_control.rb").first
- @resource = Chef::Resource::File.new("/tmp/a_file.txt")
- @resource.owner("toor")
- @resource.group("wheel")
-diff --git a/spec/unit/mixin/securable_spec.rb b/spec/unit/mixin/securable_spec.rb
-index 6f50ce8..19cecf3 100644
---- a/spec/unit/mixin/securable_spec.rb
-+++ b/spec/unit/mixin/securable_spec.rb
-@@ -46,7 +46,7 @@ describe Chef::Mixin::Securable do
- describe "unix-specific behavior" do
- before(:each) do
- platform_mock :unix do
-- load File.join(File.dirname(__FILE__), "..", "..", "..", "lib", "chef", "mixin", "securable.rb")
-+ load Gem.find_files("chef/mixin/securable.rb").first
- @securable = Object.new
- @securable.send(:extend, Chef::Mixin::Securable)
- @securable.send(:extend, Chef::Mixin::ParamsValidate)
-@@ -177,7 +177,7 @@ describe Chef::Mixin::Securable do
- describe "windows-specific behavior" do
- before(:each) do
- platform_mock :windows do
-- load File.join(File.dirname(__FILE__), "..", "..", "..", "lib", "chef", "mixin", "securable.rb")
-+ load Gem.find_files("chef/mixin/securable.rb").first
- securable_class = Class.new do
- include Chef::Mixin::Securable
- include Chef::Mixin::ParamsValidate
diff --git a/debian/patches/series b/debian/patches/series
index 491e0ef..e4c9586 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,2 @@
0001-Update-gemspec-file.patch
0002-spec-remove-absolute-require-path.patch
-0003-Make-specs-work-against-installed-package.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/chef.git
More information about the Pkg-ruby-extras-commits
mailing list