Shopify / statsd-instrument

A StatsD client for Ruby apps. Provides metaprogramming methods to inject StatsD instrumentation into your code.
http://shopify.github.io/statsd-instrument
MIT License
574 stars 97 forks source link

Rubocop: check for as_dist: true in `StatsD.measure` and `statsd_measure` #210

Closed wvanbergen closed 5 years ago

wvanbergen commented 5 years ago

Using as_dist: true is deprecated as argument to StatsD.measure (see #206).

This adds a Rubocop rule that checks for this usage, and tells people to change it to StatsD.distribution. It does the same for the statsd_measure metaprogramming method.

wvanbergen commented 5 years ago

Added some tests for the new rules, and refactored some stuff into helper methods.