inst_statsd 3.0.3 → 3.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/inst_statsd/event.rb +1 -1
- data/lib/inst_statsd/version.rb +1 -1
- data/lib/inst_statsd.rb +2 -1
- data/spec/inst_statsd/event_spec.rb +14 -0
- metadata +2 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a33a17cc0b4ff4ceba7edeb8b326e165a91a4accdf95d5b8452e5e015df793e5
|
4
|
+
data.tar.gz: e602f9889485fa588d14e8457f7cddcbe075be733f9075594a663c517ab3f07c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b4488ce5d63fb8e490ff5be51fc18e2ab36b0af52d4e0788735ea2c580fd3b4d8d02db4a4bf377c1c43e6847c8a1d5bec6719d8073a38129b91f75871a4a6773
|
7
|
+
data.tar.gz: 171e4007599cef67ad980034ab702d6575891ccc286d7769df11ce264fd93a6e61df29d542fffd39d094171ea0e4703c2d9d73941dbef203f359bc4bfaba028c
|
data/lib/inst_statsd/event.rb
CHANGED
@@ -57,7 +57,7 @@ module InstStatsd
|
|
57
57
|
|
58
58
|
def tags_from_opts(tags, type, dd_tags)
|
59
59
|
custom_tags = tags.merge(dd_tags)
|
60
|
-
custom_tags[:type] = type if SUPPORTED_TYPES.include? type
|
60
|
+
custom_tags[:type] = type.to_sym if SUPPORTED_TYPES.include? type&.to_sym
|
61
61
|
custom_tags.compact
|
62
62
|
end
|
63
63
|
end
|
data/lib/inst_statsd/version.rb
CHANGED
data/lib/inst_statsd.rb
CHANGED
@@ -105,6 +105,20 @@ RSpec.describe InstStatsd::Event do
|
|
105
105
|
end
|
106
106
|
end
|
107
107
|
|
108
|
+
context "with a valid type set as a string" do
|
109
|
+
let(:opts) { { type: "deploy" } }
|
110
|
+
|
111
|
+
it "sets the valid aggregation key" do
|
112
|
+
expect(instance).to receive(:event).with(
|
113
|
+
title,
|
114
|
+
text,
|
115
|
+
tags: { type: :deploy }
|
116
|
+
)
|
117
|
+
|
118
|
+
subject
|
119
|
+
end
|
120
|
+
end
|
121
|
+
|
108
122
|
context "with custom tags" do
|
109
123
|
let(:opts) { { tags: { project: "cool-project" } } }
|
110
124
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: inst_statsd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.
|
4
|
+
version: 3.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nick Cloward
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2024-09-11 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: aroi
|
@@ -65,20 +65,6 @@ dependencies:
|
|
65
65
|
- - "~>"
|
66
66
|
- !ruby/object:Gem::Version
|
67
67
|
version: '1.0'
|
68
|
-
- !ruby/object:Gem::Dependency
|
69
|
-
name: appraisal
|
70
|
-
requirement: !ruby/object:Gem::Requirement
|
71
|
-
requirements:
|
72
|
-
- - ">="
|
73
|
-
- !ruby/object:Gem::Version
|
74
|
-
version: '0'
|
75
|
-
type: :development
|
76
|
-
prerelease: false
|
77
|
-
version_requirements: !ruby/object:Gem::Requirement
|
78
|
-
requirements:
|
79
|
-
- - ">="
|
80
|
-
- !ruby/object:Gem::Version
|
81
|
-
version: '0'
|
82
68
|
- !ruby/object:Gem::Dependency
|
83
69
|
name: bundler
|
84
70
|
requirement: !ruby/object:Gem::Requirement
|