digitalocean / droplet_kit

DropletKit is the official DigitalOcean API client for Ruby.
MIT License
515 stars 152 forks source link

Fix two new rubocop offenses. #308

Closed andrewsomething closed 1 year ago

andrewsomething commented 1 year ago

In https://github.com/digitalocean/droplet_kit/pull/307 we are seeing two new rubocop offenses. These checks were added in recent rubocop and rubocop-rspec releases. One is a false positive that will be fixed in an upcoming rubocop-rspec release. This change gets us green again.

| Offenses:
| 
| lib/tasks/resource_doc.rake:28:49: C: [Correctable] Style/RedundantRegexpEscape: Redundant escape inside regexp literal
|         action_options = action.path.scan(/:[\w_\-]+/i)
|                                                 ^^
| spec/lib/droplet_kit/resources/database_resource_spec.rb:45:14: C: RSpec/PendingWithoutReason: Give the reason for pending.
|       expect(database_cluster.maintenance_window.pending).to be(true)
|              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
| 
| 212 files inspected, 2 offenses detected, 1 offense autocorrectable