raygun4ruby 1.4.0 → 1.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -1
- data/lib/raygun/client.rb +4 -2
- data/lib/raygun/version.rb +1 -1
- data/test/unit/client_test.rb +13 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 87bcff1d09782d4e215f3c5bcaec19c5ab14d43e
|
4
|
+
data.tar.gz: 4d033882abae5990a864817801f3c928981bb60a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 683c9f6446683722f334a370ec6e4c463fcdc43699deb9146c1bb44bfa8f9017324271036396c77639e9129e21a749655ddfbb0a9c750f0bcfa8fed7bf3c59ef
|
7
|
+
data.tar.gz: 47c6be6d9106a7eff502f64f15cc72ea751534ad239e392224388f186d8fea8e1b0c2c7b7480f5f8d585db960a711f1afc6242b3b3687577040437a36e81b5c7
|
data/CHANGELOG.md
CHANGED
data/lib/raygun/client.rb
CHANGED
@@ -176,7 +176,10 @@ module Raygun
|
|
176
176
|
error: error_details(exception_instance),
|
177
177
|
userCustomData: exception_custom_data.merge(custom_data).merge(configured_custom_data),
|
178
178
|
tags: Raygun.configuration.tags.concat(tags).compact.uniq,
|
179
|
-
request: request_information(env)
|
179
|
+
request: request_information(env),
|
180
|
+
environment: {
|
181
|
+
utcOffset: Time.now.utc_offset / 3600
|
182
|
+
}
|
180
183
|
}
|
181
184
|
|
182
185
|
error_details.merge!(groupingKey: grouping_key) if grouping_key
|
@@ -250,6 +253,5 @@ module Raygun
|
|
250
253
|
def print_api_key_warning
|
251
254
|
$stderr.puts(NO_API_KEY_MESSAGE)
|
252
255
|
end
|
253
|
-
|
254
256
|
end
|
255
257
|
end
|
data/lib/raygun/version.rb
CHANGED
data/test/unit/client_test.rb
CHANGED
@@ -30,6 +30,9 @@ class ClientTest < Raygun::UnitTest
|
|
30
30
|
super
|
31
31
|
@client = Raygun::Client.new
|
32
32
|
fake_successful_entry
|
33
|
+
|
34
|
+
# Force NZ time zone for utcOffset tests
|
35
|
+
ENV['TZ'] = 'UTC-13'
|
33
36
|
end
|
34
37
|
|
35
38
|
def test_api_key_required_message
|
@@ -57,6 +60,12 @@ class ClientTest < Raygun::UnitTest
|
|
57
60
|
assert_equal expected_message, @client.send(:error_details, e)[:message]
|
58
61
|
end
|
59
62
|
|
63
|
+
def test_utc_offset
|
64
|
+
expected = 13
|
65
|
+
|
66
|
+
assert_equal expected, @client.send(:build_payload_hash, test_exception, sample_env_hash)[:details][:environment][:utcOffset]
|
67
|
+
end
|
68
|
+
|
60
69
|
def test_inner_error_details
|
61
70
|
oe = TestException.new("A test message")
|
62
71
|
oe.set_backtrace(["/some/folder/some_file.rb:123:in `some_method_name'"])
|
@@ -178,7 +187,10 @@ class ClientTest < Raygun::UnitTest
|
|
178
187
|
userCustomData: {},
|
179
188
|
tags: ["test"],
|
180
189
|
request: {},
|
181
|
-
groupingKey: grouping_key
|
190
|
+
groupingKey: grouping_key,
|
191
|
+
environment: {
|
192
|
+
utcOffset: 13
|
193
|
+
}
|
182
194
|
}
|
183
195
|
}
|
184
196
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: raygun4ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mindscape
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2017-03-
|
12
|
+
date: 2017-03-15 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: httparty
|