summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitry Ilyin <dilyin@mirantis.com>2016-09-01 10:19:48 -0500
committerDmitry Ilyin <dilyin@mirantis.com>2016-09-01 10:19:58 -0500
commit804ed6db601dd21b12aea8d06c3ace518d0c85f0 (patch)
tree42a1ba2551e1564619374cbd046a4abddaf0a06c
parentf40a4669b9d0854f832fb2d4d7152f9668662115 (diff)
Revert "Misc fixes"
Notes
Notes (review): Code-Review+1: Vladimir Kozhukalov <vkozhukalov@mirantis.com> Code-Review+2: Dmitry Ilyin <dilyin@mirantis.com> Workflow+1: Dmitry Ilyin <dilyin@mirantis.com> Verified+2: Jenkins Submitted-by: Jenkins Submitted-at: Thu, 01 Sep 2016 15:34:35 +0000 Reviewed-on: https://review.openstack.org/364382 Project: openstack/fuel-noop-fixtures Branch: refs/heads/master
-rw-r--r--Gemfile1
-rw-r--r--lib/noop/task/facts.rb5
-rw-r--r--lib/noop/task/report.rb2
3 files changed, 3 insertions, 5 deletions
diff --git a/Gemfile b/Gemfile
index 316d132..74a52b5 100644
--- a/Gemfile
+++ b/Gemfile
@@ -11,7 +11,6 @@ group :development, :test do
11 gem 'colorize' 11 gem 'colorize'
12 gem 'parallel' 12 gem 'parallel'
13 gem 'openstack' 13 gem 'openstack'
14 gem 'activesupport', '< 5.0.0'
15end 14end
16 15
17if ENV['PUPPET_GEM_VERSION'] 16if ENV['PUPPET_GEM_VERSION']
diff --git a/lib/noop/task/facts.rb b/lib/noop/task/facts.rb
index 858243f..7aaf735 100644
--- a/lib/noop/task/facts.rb
+++ b/lib/noop/task/facts.rb
@@ -1,5 +1,4 @@
1require 'yaml' 1require 'yaml'
2require 'active_support/core_ext/hash/indifferent_access'
3 2
4module Noop 3module Noop
5 class Task 4 class Task
@@ -71,9 +70,9 @@ module Noop
71 facts_data[:puppetversion] = Puppet.version 70 facts_data[:puppetversion] = Puppet.version
72 end 71 end
73 72
74 # @return [ActiveSupport::HashWithIndifferentAccess] 73 # @return [Hash]
75 def facts_data 74 def facts_data
76 facts_data = ActiveSupport::HashWithIndifferentAccess.new 75 facts_data = {}
77 facts_hierarchy.each do |file_path| 76 facts_hierarchy.each do |file_path|
78 begin 77 begin
79 file_data = YAML.load_file file_path 78 file_data = YAML.load_file file_path
diff --git a/lib/noop/task/report.rb b/lib/noop/task/report.rb
index d118529..e477763 100644
--- a/lib/noop/task/report.rb
+++ b/lib/noop/task/report.rb
@@ -35,7 +35,7 @@ Facts hierarchy:
35 gem = gem.to_s 35 gem = gem.to_s
36 return unless Object.const_defined? 'Gem' 36 return unless Object.const_defined? 'Gem'
37 return unless Gem.loaded_specs.is_a? Hash 37 return unless Gem.loaded_specs.is_a? Hash
38 return unless Gem.loaded_specs[gem].respond_to? :version 38 return unless Gem.loaded_specs[gem].is_a? Gem::Specification
39 Gem.loaded_specs[gem].version 39 Gem.loaded_specs[gem].version
40 end 40 end
41 41