diff options
author | AJ Christensen <aj@opscode.com> | 2009-03-11 13:32:10 -0700 |
---|---|---|
committer | AJ Christensen <aj@junglist.gen.nz> | 2009-05-12 16:08:08 +1200 |
commit | dcb2f0f89e0f19bfd82f890e359d28e476f784f6 (patch) | |
tree | 0dc771c6235d08d780db6f759f0ebfc124de9b5d /spec | |
parent | a136f9823b8b0fa01da4e758e64c89bbab0036dc (diff) | |
download | mixlib-log-dcb2f0f89e0f19bfd82f890e359d28e476f784f6.tar.gz |
Convert to jeweler
Diffstat (limited to 'spec')
-rw-r--r-- | spec/mixlib/log_spec.rb | 8 | ||||
-rw-r--r-- | spec/spec_helper.rb | 4 |
2 files changed, 8 insertions, 4 deletions
diff --git a/spec/mixlib/log_spec.rb b/spec/mixlib/log_spec.rb index 4621969..259ae36 100644 --- a/spec/mixlib/log_spec.rb +++ b/spec/mixlib/log_spec.rb @@ -20,6 +20,12 @@ require 'tempfile' require File.expand_path(File.join(File.dirname(__FILE__), "..", "spec_helper")) describe Mixlib::Log do + + # Since we are testing class behaviour for an instance variable + # that gets set once, we need to reset it prior to each example [cb] + before(:each) do + Logit.instance_variable_set("@logger",nil) + end it "should accept regular options to Logger.new via init" do tf = Tempfile.new("chef-test-log") @@ -59,4 +65,4 @@ describe Mixlib::Log do Logit.init end -end
\ No newline at end of file +end diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 2680dba..518498d 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -5,7 +5,5 @@ require 'mixlib/log' require 'mixlib/log/formatter' class Logit - class << self - include Mixlib::Log - end + extend(Mixlib::Log) end
\ No newline at end of file |