Skip to content

Commit

Permalink
Merge pull request #1293 from LuvCurves/stable
Browse files Browse the repository at this point in the history
(FACT-1340) Update acceptance tests for Cisco platforms
  • Loading branch information
Michael Smith committed Mar 31, 2016
2 parents 30189ca + ffbfca2 commit 32a6e65
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 2 deletions.
2 changes: 2 additions & 0 deletions acceptance/tests/facts/ruby.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
else
ruby_platform = /i386-solaris[\d.]+/
end
when /cisco_ios_xr/
ruby_platform = /x86_64-linux/
else
if agent['ruby_arch']
ruby_platform = agent['ruby_arch'] == 'x64' ? 'x86_64-linux' : /i(4|6)86-linux/
Expand Down
1 change: 1 addition & 0 deletions acceptance/tests/options/custom_facts.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
test_name "custom fact commandline options (--no-custom-facts and --custom-dir)"
confine :except, :platform => 'cisco_nexus' # see BKR-749

require 'puppet/acceptance/common_utils'
extend Puppet::Acceptance::CommandUtils
Expand Down
5 changes: 3 additions & 2 deletions acceptance/tests/ticket_1123_facter_with_invalid_locale.rb
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
test_name 'ticket 1123 facter should not crash with invalid locale setting'
confine :except, :platform => 'windows'
confine :except, :platform => /^cisco_/ # See CISCO-43

agents.each do |host|
step 'set an invalid value for locale and run facter'
result = on host, 'LANG=ABCD facter facterversion'
if host['platform'] !~ /solaris|aix|cumulus|osx|cisco/
if host['platform'] !~ /solaris|aix|cumulus|osx/
fail_test 'facter did not warn about the locale' unless
result.stderr.include? 'locale environment variables were bad; continuing with LANG=C'
end
fail_test 'facter did not continue running' unless
result.stdout =~ /^\d+\.\d+\.\d+$/
end

1 change: 1 addition & 0 deletions acceptance/tests/verify_facts.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
test_name "verify facts match the schema"
confine :except, :platform => 'cisco_ios_xr'

require 'yaml'
require 'set'
Expand Down

0 comments on commit 32a6e65

Please sign in to comment.