mongoid-clerk 0.0.3 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- mongoid-clerk (0.0.2)
4
+ mongoid-clerk (0.0.3)
5
5
  activesupport
6
6
  bson_ext
7
7
  foreman
@@ -29,7 +29,7 @@ GEM
29
29
  i18n (0.6.0)
30
30
  mongo (1.6.2)
31
31
  bson (~> 1.6.2)
32
- mongoid (2.4.11)
32
+ mongoid (2.4.12)
33
33
  activemodel (~> 3.1)
34
34
  mongo (<= 1.6.2)
35
35
  tzinfo (~> 0.3.22)
data/lib/clerk/logger.rb CHANGED
@@ -23,7 +23,7 @@ module Clerk::Logger
23
23
  end
24
24
 
25
25
  def log(msg, level = :info)
26
- Clerk::Log.create!(
26
+ log_items.create!(
27
27
  included_fields.merge(
28
28
  :message => msg,
29
29
  :level => level
data/lib/clerk/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Clerk
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
@@ -69,7 +69,7 @@ describe MongoidDocumentWithClerk do
69
69
  context "with default values" do
70
70
 
71
71
  it "should call Clerk::Log with the correct params" do
72
- Clerk::Log.should_receive(:create!).with(
72
+ document_with_clerk.log_items.should_receive(:create!).with(
73
73
  :name => 'James Bond',
74
74
  :place => 'Secret',
75
75
  :message => 'bananas',
@@ -83,7 +83,7 @@ describe MongoidDocumentWithClerk do
83
83
  context "with overriden status level" do
84
84
 
85
85
  it "should call Clerk::Log with the correct params" do
86
- Clerk::Log.should_receive(:create!).with(
86
+ document_with_clerk.log_items.should_receive(:create!).with(
87
87
  :name => 'James Bond',
88
88
  :place => 'Secret',
89
89
  :message => 'bananas',
data/spec/spec_helper.rb CHANGED
@@ -8,7 +8,6 @@ require 'mongoid'
8
8
  require 'uri'
9
9
  require 'mongoid-rspec'
10
10
 
11
-
12
11
  mongoid_config = YAML.load_file(File.join(File.dirname(__FILE__),"mongoid.yml"))['test']
13
12
 
14
13
  Mongoid.configure do |config|
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mongoid-clerk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: