Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/stable'
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Smith committed Apr 11, 2016
2 parents d83d164 + dc7d029 commit a664e68
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion acceptance/Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ module HarnessOptions
:xml => true,
:timesync => false,
:repo_proxy => true,
:add_el_extras => true,
:add_el_extras => false,
:preserve_hosts => 'onfail',
}

Expand Down
2 changes: 2 additions & 0 deletions acceptance/tests/facts/ruby.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@
end
when /cisco_ios_xr/
ruby_platform = /x86_64-linux/
when /huaweios/
ruby_platform = /powerpc-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 lib/tests/facts/schema.cc
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ using namespace std;
using namespace facter::facts;
using namespace leatherman::util;
using namespace facter::testing;
using Catch::Matchers::AnyOf;

// For every base resolver, implement a resolver that outputs the minimum values to pass schema validation
// We don't care about the actual data in the facts, only that it conforms to the schema
Expand Down
11 changes: 11 additions & 0 deletions lib/tests/fixtures.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
#include <iostream>
#include <sstream>

#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstrict-aliasing"
#include <boost/thread/thread.hpp>
#include <boost/chrono/duration.hpp>
#pragma GCC diagnostic pop

using namespace std;
using namespace boost::filesystem;

Expand Down Expand Up @@ -45,6 +51,11 @@ namespace facter { namespace testing {
{
if (!_dir.empty()) {
remove_all(_dir);
// Wait for at most 5 seconds to ensure the directory is destroyed.
int count = 50;
while (exists(_dir) && --count > 0) {
boost::this_thread::sleep_for(boost::chrono::milliseconds(100));
}
}
}

Expand Down

0 comments on commit a664e68

Please sign in to comment.