exceptional 2.0.29 → 2.0.30

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.
@@ -21,6 +21,7 @@ require 'exceptional/railtie' if defined?(Rails::Railtie)
21
21
  module Exceptional
22
22
  PROTOCOL_VERSION = 5
23
23
  CLIENT_NAME = 'getexceptional-gem'
24
+ ENVIRONMENT_FILTER = []
24
25
 
25
26
  def self.logger
26
27
  ::Exceptional::LogFactory.logger
@@ -32,7 +32,9 @@ module Exceptional
32
32
  end
33
33
 
34
34
  def self.extract_environment(env)
35
- env.reject{|k, v| k =~ /^HTTP_/}
35
+ env.reject do |k, v|
36
+ (k =~ /^HTTP_/) || Exceptional::ENVIRONMENT_FILTER.include?(k)
37
+ end
36
38
  end
37
39
 
38
40
  def self.get_hostname
@@ -1,3 +1,3 @@
1
1
  module Exceptional
2
- VERSION = '2.0.29'
2
+ VERSION = '2.0.30'
3
3
  end
@@ -26,6 +26,8 @@ describe Exceptional::ControllerExceptionData, 'when no request/controller/param
26
26
  before :each do
27
27
  ENV['LOGNAME'] = 'bob'
28
28
  ENV['SOMEVAR'] = 'something'
29
+ ENV['SOMEOTHERVAR'] = 'something else'
30
+ Exceptional::ENVIRONMENT_FILTER << 'SOMEOTHERVAR'
29
31
  ENV['HTTP_SOMETHING'] = 'should be stripped'
30
32
  ::RAILS_ENV = 'test' unless defined?(RAILS_ENV)
31
33
  Time.stub!(:now).and_return(Time.mktime(1970, 1, 1))
@@ -56,6 +58,7 @@ describe Exceptional::ControllerExceptionData, 'when no request/controller/param
56
58
  application_env_hash['environment'].should == 'test'
57
59
  application_env_hash['env'].should_not be_nil
58
60
  application_env_hash['env']['SOMEVAR'].should == 'something'
61
+ application_env_hash['env']['SOMEOTHERVAR'].should == nil
59
62
  application_env_hash['host'].should == `hostname`.strip
60
63
  application_env_hash['run_as_user'].should == 'bob'
61
64
  application_env_hash['application_root_directory'].should == Dir.pwd
metadata CHANGED
@@ -1,13 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: exceptional
3
3
  version: !ruby/object:Gem::Version
4
- hash: 53
5
4
  prerelease: false
6
5
  segments:
7
6
  - 2
8
7
  - 0
9
- - 29
10
- version: 2.0.29
8
+ - 30
9
+ version: 2.0.30
11
10
  platform: ruby
12
11
  authors:
13
12
  - Contrast
@@ -15,7 +14,7 @@ autorequire:
15
14
  bindir: bin
16
15
  cert_chain: []
17
16
 
18
- date: 2010-12-01 00:00:00 +00:00
17
+ date: 2010-12-08 00:00:00 +00:00
19
18
  default_executable:
20
19
  dependencies:
21
20
  - !ruby/object:Gem::Dependency
@@ -26,7 +25,6 @@ dependencies:
26
25
  requirements:
27
26
  - - ">="
28
27
  - !ruby/object:Gem::Version
29
- hash: 3
30
28
  segments:
31
29
  - 0
32
30
  version: "0"
@@ -104,7 +102,6 @@ required_ruby_version: !ruby/object:Gem::Requirement
104
102
  requirements:
105
103
  - - ">="
106
104
  - !ruby/object:Gem::Version
107
- hash: 3
108
105
  segments:
109
106
  - 0
110
107
  version: "0"
@@ -113,7 +110,6 @@ required_rubygems_version: !ruby/object:Gem::Requirement
113
110
  requirements:
114
111
  - - ">="
115
112
  - !ruby/object:Gem::Version
116
- hash: 3
117
113
  segments:
118
114
  - 0
119
115
  version: "0"