inst_statsd 3.0.4 → 3.0.5

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a91fe00f6ca513926589fdd5d3cb3f316e26a6fc5bb5b8ceb1a49ba20f42769f
4
- data.tar.gz: 82a6dd4759cb55054a20e6c394d19c000b571aabe8df48251f0661fdb86de7ec
3
+ metadata.gz: a33a17cc0b4ff4ceba7edeb8b326e165a91a4accdf95d5b8452e5e015df793e5
4
+ data.tar.gz: e602f9889485fa588d14e8457f7cddcbe075be733f9075594a663c517ab3f07c
5
5
  SHA512:
6
- metadata.gz: dbddd5f2e3069681cd2f6e4b2843d4c7ea123cbaee2a3537cd35ef4b6fffe8f2c90b20b4bf30d5e109967151d29926ad993597575ee6042942587ef7ba75fa43
7
- data.tar.gz: e5d8af2078d7d320732285b3e071c1c18da70e9aeb0cad060eb589b8b1de592d6093fab0d836c74a9380e10df19e3f46090edb73a14bf1a18e8a2e5d95bf51fa
6
+ metadata.gz: b4488ce5d63fb8e490ff5be51fc18e2ab36b0af52d4e0788735ea2c580fd3b4d8d02db4a4bf377c1c43e6847c8a1d5bec6719d8073a38129b91f75871a4a6773
7
+ data.tar.gz: 171e4007599cef67ad980034ab702d6575891ccc286d7769df11ce264fd93a6e61df29d542fffd39d094171ea0e4703c2d9d73941dbef203f359bc4bfaba028c
@@ -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
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module InstStatsd
4
- VERSION = "3.0.4"
4
+ VERSION = "3.0.5"
5
5
  end
@@ -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
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: 2023-09-19 00:00:00.000000000 Z
12
+ date: 2024-09-11 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: aroi