trouble 0.0.6 → 0.0.7

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -6,6 +6,12 @@ This gem achieves independence of things like Bugsnag, Airbrake, etc.. If any of
6
6
 
7
7
  Currently only Bugsnag is defined as a working backend.
8
8
 
9
+ # Installation
10
+
11
+ ```bash
12
+ gem install trouble
13
+ ````
14
+
9
15
  # Usage
10
16
 
11
17
  #### Syntax
@@ -2,7 +2,7 @@ module Trouble
2
2
  module VERSION #:nodoc:
3
3
  MAJOR = 0
4
4
  MINOR = 0
5
- TINY = 6
5
+ TINY = 7
6
6
 
7
7
  STRING = [MAJOR, MINOR, TINY].compact.join('.')
8
8
  end
data/lib/trouble.rb CHANGED
@@ -33,11 +33,7 @@ module Trouble
33
33
  # Internal: Log to the current Logger.
34
34
  #
35
35
  def self.log(exception, metadata)
36
- rows = ['TROUBLE NOTIFICATION']
37
- rows << " | Exception: #{exception.inspect}"
38
- rows << " | Metadata: #{metadata.inspect}"
39
- rows << " \\ Location: #{exception.backtrace.first}\n"
40
- config.logger.error rows.join("\n")
36
+ config.logger.error "TROUBLE NOTIFICATION #{exception.inspect} at #{exception.backtrace.first} with metadata #{metadata.inspect}"
41
37
  end
42
38
 
43
39
  end
@@ -21,7 +21,7 @@ describe Trouble do
21
21
  end
22
22
 
23
23
  it 'logs the output' do
24
- trouble.config.logger .should_receive(:error) do |string|
24
+ trouble.config.logger.should_receive(:error) do |string|
25
25
  string.should include('TROUBLE')
26
26
  string.should include('TroubleTestException')
27
27
  string.should include('big problems')
@@ -47,7 +47,7 @@ describe Trouble do
47
47
  end
48
48
  end
49
49
 
50
- describe '.logger' do
50
+ describe '.config' do
51
51
  before do
52
52
  Trouble.reset!
53
53
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trouble
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-03-12 00:00:00.000000000 Z
12
+ date: 2013-03-13 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rspec
@@ -59,8 +59,9 @@ dependencies:
59
59
  - - ! '>='
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0'
62
- description: This gem achieves independence of things like Bugsnag, Airbrake, etc..
63
- If any of those is defined, Trouble will pass on the exception to them.
62
+ description: A generic abstraction layer for reporting errors and Exceptions. This
63
+ gem achieves independence of things like Bugsnag, Airbrake, etc.. If any of those
64
+ is defined, Trouble will pass on the exception to them.
64
65
  email:
65
66
  executables: []
66
67
  extensions: []