FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Deprecator improvements by stefannibrasil · Pull Request #2997 · faker-ruby/faker · GitHub

Deprecator improvements - #2997

Merged
stefannibrasil merged 2 commits into
mainfrom
sb-deprecator-improvements
Sep 12, 2024
Merged

Deprecator improvements#2997
stefannibrasil merged 2 commits into
mainfrom
sb-deprecator-improvements

Conversation

Copy link
Copy Markdown
Contributor

In preparation for removing deprecations for certain generators, this commit documents the Deprecator and how to test deprecated generators. It also adds a unit test using newly added matchers based on Rails deprecation matchers. This new test is independent from any "real" deprecated generator that can be removed at any time.

With this change, we can remove generators in a follow up PR while having the Deprecator covered and documented.

In preparation for removing deprecations for certain generators,
this commit documents the Deprecator and how to test deprecated
generators. It also adds a unit test using newly added matchers
based on Rails deprecation matchers.

With this change, we can remove generators in a follow up PR
while having the Deprecator covered and documented.
stefannibrasil force-pushed the sb-deprecator-improvements branch from c53bade to f86ba5e Compare August 30, 2024 17:39
Comment thread lib/helpers/deprecator.rb

# Based on Rails ActiveSupport Deprecator
# https://github.com/rails/rails/blob/6f0d1ad14b92b9f5906e44740fce8b4f1c7075dc/activesupport/lib/active_support/deprecation/constant_accessor.rb
# https://github.com/rails/rails/blob/main/activesupport/lib/active_support/deprecation/constant_accessor.rb

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

The changes here are mostly documentation and identation.

@@ -0,0 +1,41 @@
# frozen_string_literal: true

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Moved this file from test/faker/ to test/faker/support.

stefannibrasil force-pushed the sb-deprecator-improvements branch from a9fabc2 to f3102de Compare August 30, 2024 18:00
Comment thread Gemfile

gem 'benchmark'
gem 'minitest', '5.25.0'
gem 'minitest', '5.25.1'

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Ruby head was not happy with the old version. This new version works for all Ruby versions in CI.

stefannibrasil force-pushed the sb-deprecator-improvements branch from f3102de to d8b2327 Compare August 30, 2024 18:20
stefannibrasil merged commit b09aa0d into main Sep 12, 2024
stefannibrasil deleted the sb-deprecator-improvements branch September 12, 2024 16:34
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant


Back | FazBrowse Home | New Git URL