diff options
author | Matt Robinson <matt@puppetlabs.com> | 2011-04-11 15:50:43 -0700 |
---|---|---|
committer | Matt Robinson <matt@puppetlabs.com> | 2011-04-11 15:50:43 -0700 |
commit | 4f7ad86adaa3a359761fac2aacf88f56461395bb (patch) | |
tree | 13be46964c4427806f65869ee5906689b6c36555 | |
parent | 229d11118f06d7daa7ba3fe6278268cbd1a12534 (diff) | |
parent | 23c9663d2142b9c674257fd47952d5e58c8ca7a7 (diff) | |
download | puppet-4f7ad86adaa3a359761fac2aacf88f56461395bb.tar.gz puppet-4f7ad86adaa3a359761fac2aacf88f56461395bb.tar.xz puppet-4f7ad86adaa3a359761fac2aacf88f56461395bb.zip |
Merge branch 'ticket/2.6.next/maint-fix_sqlite_test' into 2.6.next
* ticket/2.6.next/maint-fix_sqlite_test:
maint: Fix sqlite3 require to really be optional
maint: Fix sporadic sqlite error
-rw-r--r-- | spec/unit/indirector/facts/inventory_active_record_spec.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/spec/unit/indirector/facts/inventory_active_record_spec.rb b/spec/unit/indirector/facts/inventory_active_record_spec.rb index 9558abde2..022150c76 100644 --- a/spec/unit/indirector/facts/inventory_active_record_spec.rb +++ b/spec/unit/indirector/facts/inventory_active_record_spec.rb @@ -1,7 +1,10 @@ #!/usr/bin/env ruby require File.dirname(__FILE__) + '/../../../spec_helper' -require 'sqlite3' rescue nil +begin + require 'sqlite3' +rescue LoadError +end require 'tempfile' require 'puppet/rails' @@ -29,6 +32,7 @@ describe "Puppet::Node::Facts::InventoryActiveRecord", :if => (Puppet.features.r after :each do Puppet::Rails.teardown + ActiveRecord::Base.remove_connection end describe "#save" do |