radius-spec 0.7.0 → 0.8.0
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 +4 -4
- data/.github/workflows/ci.yml +28 -0
- data/.github/workflows/reviewdog.yml +21 -0
- data/.rubocop.yml +6 -6
- data/CHANGELOG.md +29 -4
- data/Gemfile +1 -3
- data/README.md +5 -6
- data/benchmarks/call_vs_yield.rb +0 -2
- data/benchmarks/cover_vs_include.rb +2 -2
- data/benchmarks/format_string.rb +3 -3
- data/benchmarks/hash_each.rb +305 -0
- data/benchmarks/hash_merge.rb +1 -1
- data/benchmarks/hash_transform.rb +455 -0
- data/benchmarks/unfreeze_string.rb +0 -2
- data/common_rubocop.yml +54 -41
- data/common_rubocop_rails.yml +33 -9
- data/lib/radius/spec/model_factory.rb +0 -2
- data/lib/radius/spec/vcr.rb +0 -2
- data/lib/radius/spec/version.rb +1 -1
- data/radius-spec.gemspec +6 -6
- metadata +12 -10
- data/.travis.yml +0 -15
- data/bin/ci-code-review +0 -28
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: c90e6b5072e71e6bb5c5ef37ccbbc9f0b874c151d156bdb3e9af92aeba0caeb1
         | 
| 4 | 
            +
              data.tar.gz: 2781ec9668af9583f4ac7c73de5de2f52e634e3d063e94feb305095de4b36f75
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 9b685ea0852391ce5a52c1810bd10d923ff007d9968a4dce483ca147d2057c0e320c15c413abcef900c810cb241dc98b2e633d7b65176a87fbc863d5f2dad26b
         | 
| 7 | 
            +
              data.tar.gz: 97ea01566899ea8641f86771f54147875e649eb18669871b2f6db640d6bce912982e5e53690b051b70aece3cd231275fe38c074c3e28cdc5670860c04d6579e4
         | 
| @@ -0,0 +1,28 @@ | |
| 1 | 
            +
            # This workflow uses actions that are not certified by GitHub.
         | 
| 2 | 
            +
            # They are provided by a third-party and are governed by
         | 
| 3 | 
            +
            # separate terms of service, privacy policy, and support
         | 
| 4 | 
            +
            # documentation.
         | 
| 5 | 
            +
            # This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
         | 
| 6 | 
            +
            # For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
         | 
| 7 | 
            +
             | 
| 8 | 
            +
            name: Ruby
         | 
| 9 | 
            +
             | 
| 10 | 
            +
            on: [push, pull_request]
         | 
| 11 | 
            +
             | 
| 12 | 
            +
            jobs:
         | 
| 13 | 
            +
              test:
         | 
| 14 | 
            +
             | 
| 15 | 
            +
                runs-on: ubuntu-latest
         | 
| 16 | 
            +
                strategy:
         | 
| 17 | 
            +
                  matrix:
         | 
| 18 | 
            +
                    ruby-version: ['2.5', '2.6', '2.7']
         | 
| 19 | 
            +
             | 
| 20 | 
            +
                steps:
         | 
| 21 | 
            +
                - uses: actions/checkout@v2
         | 
| 22 | 
            +
                - name: Set up Ruby
         | 
| 23 | 
            +
                  uses: ruby/setup-ruby@v1
         | 
| 24 | 
            +
                  with:
         | 
| 25 | 
            +
                    ruby-version: ${{ matrix.ruby-version }}
         | 
| 26 | 
            +
                    bundler-cache: true # runs 'bundle install' and caches installed gems automatically
         | 
| 27 | 
            +
                - name: Run tests
         | 
| 28 | 
            +
                  run: ./bin/ci
         | 
| @@ -0,0 +1,21 @@ | |
| 1 | 
            +
            name: Review Dog
         | 
| 2 | 
            +
            on: [pull_request]
         | 
| 3 | 
            +
            jobs:
         | 
| 4 | 
            +
              rubocop:
         | 
| 5 | 
            +
                name: Rubocop
         | 
| 6 | 
            +
                runs-on: ubuntu-latest
         | 
| 7 | 
            +
                steps:
         | 
| 8 | 
            +
                  - name: Check out code
         | 
| 9 | 
            +
                    uses: actions/checkout@v1
         | 
| 10 | 
            +
                  - uses: ruby/setup-ruby@v1 # ruby-version pulled .ruby-version file automatically
         | 
| 11 | 
            +
                    with:
         | 
| 12 | 
            +
                      ruby-version: '2.7'
         | 
| 13 | 
            +
                      bundler-cache: true
         | 
| 14 | 
            +
                  - name: rubocop
         | 
| 15 | 
            +
                    uses: reviewdog/action-rubocop@v1
         | 
| 16 | 
            +
                    with:
         | 
| 17 | 
            +
                      github_token: ${{ secrets.github_token }}
         | 
| 18 | 
            +
                      reporter: github-pr-review # Default is github-pr-check
         | 
| 19 | 
            +
                      rubocop_version: gemfile
         | 
| 20 | 
            +
                      rubocop_extensions: rubocop-rails:gemfile
         | 
| 21 | 
            +
             | 
    
        data/.rubocop.yml
    CHANGED
    
    | @@ -5,18 +5,18 @@ inherit_mode: | |
| 5 5 |  | 
| 6 6 | 
             
            inherit_from: common_rubocop_rails.yml
         | 
| 7 7 |  | 
| 8 | 
            +
            # Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
         | 
| 9 | 
            +
            # URISchemes: http, https
         | 
| 10 | 
            +
            Layout/LineLength:
         | 
| 11 | 
            +
              Exclude:
         | 
| 12 | 
            +
                - 'radius-spec.gemspec'
         | 
| 13 | 
            +
             | 
| 8 14 | 
             
            # Configuration parameters: CountComments, ExcludedMethods.
         | 
| 9 15 | 
             
            Metrics/BlockLength:
         | 
| 10 16 | 
             
              Exclude:
         | 
| 11 17 | 
             
                - 'benchmarks/**/*'
         | 
| 12 18 | 
             
                - 'lib/radius/spec/rspec.rb'
         | 
| 13 19 |  | 
| 14 | 
            -
            # Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
         | 
| 15 | 
            -
            # URISchemes: http, https
         | 
| 16 | 
            -
            Metrics/LineLength:
         | 
| 17 | 
            -
              Exclude:
         | 
| 18 | 
            -
                - 'radius-spec.gemspec'
         | 
| 19 | 
            -
             | 
| 20 20 | 
             
            Style/Documentation:
         | 
| 21 21 | 
             
              Exclude:
         | 
| 22 22 | 
             
                - 'benchmarks/**/*'
         | 
    
        data/CHANGELOG.md
    CHANGED
    
    | @@ -1,14 +1,39 @@ | |
| 1 | 
            +
            ## 0.8.0 (August 26, 2021)
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            [Full Changelog](https://github.com/RadiusNetworks/radius-spec/compare/v0.7.0...v0.8.0)
         | 
| 4 | 
            +
             | 
| 5 | 
            +
            ### Enhancements
         | 
| 6 | 
            +
             | 
| 7 | 
            +
            - Upgrade to Rubocop 0.82.x (Aaron Hill, Aaron Kromer, Ben Reynolds, Chris
         | 
| 8 | 
            +
              Hoffman, James Nebeker, JC Avena #26)
         | 
| 9 | 
            +
            - Upgrade to Rubocop Rails 2.5.x (Aaron Hill, Aaron Kromer, Ben Reynolds, Chris
         | 
| 10 | 
            +
              Hoffman, James Nebeker, JC Avena #26)
         | 
| 11 | 
            +
            - Adjust common Rubocop configuration (Aaron Hill, Aaron Kromer, Ben Reynolds,
         | 
| 12 | 
            +
              Chris Hoffman, James Nebeker, JC Avena #26)
         | 
| 13 | 
            +
              - Rename metrics/configuration parameters per version upgrade requirements
         | 
| 14 | 
            +
              - Use the stricter `always_true` check for `Style/FrozenStringLiteralComment`
         | 
| 15 | 
            +
              - Opt-in to new cops/checks behaving per their default settings
         | 
| 16 | 
            +
            - Adjust common Rubocop Rails configuration (Aaron Hill, Aaron Kromer, Ben
         | 
| 17 | 
            +
              Reynolds, Chris Hoffman, James Nebeker, JC Avena #26)
         | 
| 18 | 
            +
              - Disable `Rails/IndexBy` by default
         | 
| 19 | 
            +
              - Disable `Rails/IndexWith` by default
         | 
| 20 | 
            +
             | 
| 21 | 
            +
            ### Bug Fixes
         | 
| 22 | 
            +
             | 
| 23 | 
            +
            None
         | 
| 24 | 
            +
             | 
| 25 | 
            +
             | 
| 1 26 | 
             
            ## 0.7.0 (July 23, 2021)
         | 
| 2 27 |  | 
| 3 28 | 
             
            [Full Changelog](https://github.com/RadiusNetworks/radius-spec/compare/v0.6.0...0.7.0)
         | 
| 4 29 |  | 
| 5 30 | 
             
            ### Enhancements
         | 
| 6 31 |  | 
| 7 | 
            -
            - Upgrade to Rubocop 0.73.x (Aaron Hill, Aaron Kromer, Ben  | 
| 32 | 
            +
            - Upgrade to Rubocop 0.73.x (Aaron Hill, Aaron Kromer, Ben Reynolds, Chris
         | 
| 8 33 | 
             
              Hoffman, James Nebeker #24)
         | 
| 9 | 
            -
            - Upgrade to Rubocop Rails 2.2.x (Aaron Hill, Aaron Kromer, Ben  | 
| 34 | 
            +
            - Upgrade to Rubocop Rails 2.2.x (Aaron Hill, Aaron Kromer, Ben Reynolds, Chris
         | 
| 10 35 | 
             
              Hoffman, James Nebeker #24)
         | 
| 11 | 
            -
            - Adjust common Rubocop configuration (Aaron Hill, Aaron Kromer, Ben  | 
| 36 | 
            +
            - Adjust common Rubocop configuration (Aaron Hill, Aaron Kromer, Ben Reynolds,
         | 
| 12 37 | 
             
              Chris Hoffman, James Nebeker #24)
         | 
| 13 38 | 
             
              - Target Ruby 2.7 by default
         | 
| 14 39 | 
             
              - Enable `Lint/HeredocMethodCallPosition` by default
         | 
| @@ -16,7 +41,7 @@ | |
| 16 41 | 
             
              - Bump metric check maximums to provide a little more wiggle room
         | 
| 17 42 | 
             
              - Disable `Naming/RescuedExceptionsVariableName` by default
         | 
| 18 43 | 
             
            - Adjust common Rubocop Rails configuration (Aaron Hill, Aaron Kromer, Ben
         | 
| 19 | 
            -
               | 
| 44 | 
            +
              Reynolds, Chris Hoffman, James Nebeker #24)
         | 
| 20 45 | 
             
              - Disable `Rails/IgnoredSkipActionFilterOption` by default
         | 
| 21 46 |  | 
| 22 47 | 
             
            ### Bug Fixes
         | 
    
        data/Gemfile
    CHANGED
    
    | @@ -10,9 +10,7 @@ gemspec | |
| 10 10 | 
             
            group :benchmark, optional: true do
         | 
| 11 11 | 
             
              gem 'activesupport', require: false
         | 
| 12 12 | 
             
              gem 'benchmark-ips', require: false
         | 
| 13 | 
            -
               | 
| 14 | 
            -
              # strict and it was blocking other gems from installing / updating
         | 
| 15 | 
            -
              gem 'kalibera', require: false, git: 'https://github.com/cupakromer/libkalibera.git'
         | 
| 13 | 
            +
              gem 'kalibera', require: false
         | 
| 16 14 | 
             
            end
         | 
| 17 15 |  | 
| 18 16 | 
             
            group :debug do
         | 
    
        data/README.md
    CHANGED
    
    | @@ -1,6 +1,5 @@ | |
| 1 1 | 
             
            # Common RSpec Setup and Plug-ins
         | 
| 2 2 |  | 
| 3 | 
            -
            [](https://travis-ci.org/RadiusNetworks/radius-spec)
         | 
| 4 3 | 
             
            [](https://codeclimate.com/github/RadiusNetworks/radius-spec/maintainability)
         | 
| 5 4 | 
             
            [](https://badge.fury.io/rb/radius-spec)
         | 
| 6 5 |  | 
| @@ -123,17 +122,17 @@ inherit_mode: | |
| 123 122 |  | 
| 124 123 | 
             
            # Available for projects which cannot include this gem (i.e. Ruby < 2.5)
         | 
| 125 124 | 
             
            inherit_from:
         | 
| 126 | 
            -
              - https://raw.githubusercontent.com/RadiusNetworks/radius-spec/ | 
| 125 | 
            +
              - https://raw.githubusercontent.com/RadiusNetworks/radius-spec/main/common_rubocop.yml
         | 
| 127 126 | 
             
              # Use the following instead if it is a Rails project
         | 
| 128 | 
            -
              - https://raw.githubusercontent.com/RadiusNetworks/radius-spec/ | 
| 127 | 
            +
              - https://raw.githubusercontent.com/RadiusNetworks/radius-spec/main/common_rubocop_rails.yml
         | 
| 129 128 | 
             
            ```
         | 
| 130 129 |  | 
| 131 130 | 
             
            When using the raw URL you may need to add the following to the project's
         | 
| 132 131 | 
             
            `.gitignore` file:
         | 
| 133 132 |  | 
| 134 133 | 
             
            ```
         | 
| 135 | 
            -
            .rubocop-https---raw-githubusercontent-com-RadiusNetworks-radius-spec- | 
| 136 | 
            -
            .rubocop-https---raw-githubusercontent-com-RadiusNetworks-radius-spec- | 
| 134 | 
            +
            .rubocop-https---raw-githubusercontent-com-RadiusNetworks-radius-spec-main-common-rubocop-rails-yml
         | 
| 135 | 
            +
            .rubocop-https---raw-githubusercontent-com-RadiusNetworks-radius-spec-main-common-rubocop-yml
         | 
| 137 136 | 
             
            ```
         | 
| 138 137 |  | 
| 139 138 | 
             
            #### General Inheritance Notes
         | 
| @@ -798,4 +797,4 @@ conduct. | |
| 798 797 |  | 
| 799 798 | 
             
            Everyone interacting in the Radius::Spec project’s codebases, issue trackers,
         | 
| 800 799 | 
             
            chat rooms and mailing lists is expected to follow the [code of
         | 
| 801 | 
            -
            conduct](https://github.com/RadiusNetworks/radius-spec/blob/ | 
| 800 | 
            +
            conduct](https://github.com/RadiusNetworks/radius-spec/blob/main/CODE_OF_CONDUCT.md).
         | 
    
        data/benchmarks/call_vs_yield.rb
    CHANGED
    
    | @@ -5,7 +5,6 @@ require_relative 'bm_setup' | |
| 5 5 |  | 
| 6 6 | 
             
            display_benchmark_header
         | 
| 7 7 |  | 
| 8 | 
            -
            # rubocop:disable Performance/RedundantBlockCall
         | 
| 9 8 | 
             
            def block_call(&block)
         | 
| 10 9 | 
             
              block.call
         | 
| 11 10 | 
             
            end
         | 
| @@ -77,7 +76,6 @@ section "Block call vs yield" do |bench| | |
| 77 76 | 
             
                end
         | 
| 78 77 | 
             
              end
         | 
| 79 78 | 
             
            end
         | 
| 80 | 
            -
            # rubocop:enable Performance/RedundantBlockCall
         | 
| 81 79 |  | 
| 82 80 | 
             
            __END__
         | 
| 83 81 |  | 
| @@ -5,7 +5,7 @@ require_relative 'bm_setup' | |
| 5 5 |  | 
| 6 6 | 
             
            display_benchmark_header
         | 
| 7 7 |  | 
| 8 | 
            -
            INT_RANGE = (0..15)
         | 
| 8 | 
            +
            INT_RANGE = (0..15).freeze
         | 
| 9 9 | 
             
            INT_VAR = 10
         | 
| 10 10 |  | 
| 11 11 | 
             
            section "Integer ranges" do |bench|
         | 
| @@ -30,7 +30,7 @@ BEGIN_OF_JULY = Time.utc(2015, 7, 1) | |
| 30 30 | 
             
            END_OF_JULY = Time.utc(2015, 7, 31)
         | 
| 31 31 | 
             
            DAY_IN_JULY = Time.utc(2015, 7, 15)
         | 
| 32 32 |  | 
| 33 | 
            -
            TIME_RANGE = (BEGIN_OF_JULY..END_OF_JULY)
         | 
| 33 | 
            +
            TIME_RANGE = (BEGIN_OF_JULY..END_OF_JULY).freeze
         | 
| 34 34 |  | 
| 35 35 | 
             
            section "Time ranges" do |bench|
         | 
| 36 36 | 
             
              bench.report('range#cover?') do
         | 
    
        data/benchmarks/format_string.rb
    CHANGED
    
    | @@ -15,15 +15,15 @@ MULTI_TOKEN_HASH = { | |
| 15 15 | 
             
            # rubocop:disable Style/FormatString
         | 
| 16 16 | 
             
            section "Format String" do |bench|
         | 
| 17 17 | 
             
              bench.report("String#%") do
         | 
| 18 | 
            -
                '%10s' % 'hoge'
         | 
| 18 | 
            +
                '%10s' % 'hoge' # rubocop:disable Style/FormatStringToken
         | 
| 19 19 | 
             
              end
         | 
| 20 20 |  | 
| 21 21 | 
             
              bench.report("format") do
         | 
| 22 | 
            -
                format '%10s', 'hoge'
         | 
| 22 | 
            +
                format '%10s', 'hoge' # rubocop:disable Style/FormatStringToken
         | 
| 23 23 | 
             
              end
         | 
| 24 24 |  | 
| 25 25 | 
             
              bench.report("sprintf") do
         | 
| 26 | 
            -
                sprintf '%10s', 'hoge'
         | 
| 26 | 
            +
                sprintf '%10s', 'hoge' # rubocop:disable Style/FormatStringToken
         | 
| 27 27 | 
             
              end
         | 
| 28 28 | 
             
            end
         | 
| 29 29 | 
             
            # rubocop:enable Style/FormatString
         | 
| @@ -0,0 +1,305 @@ | |
| 1 | 
            +
            # frozen_string_literal: true
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            # Run from the command line: bundle exec ruby benchmarks/hash_merge.rb
         | 
| 4 | 
            +
            require_relative 'bm_setup'
         | 
| 5 | 
            +
             | 
| 6 | 
            +
            # rubocop:disable Style/HashEachMethods
         | 
| 7 | 
            +
             | 
| 8 | 
            +
            display_benchmark_header
         | 
| 9 | 
            +
             | 
| 10 | 
            +
            # Bad per Rubocop
         | 
| 11 | 
            +
            def hash_keys_each(hash)
         | 
| 12 | 
            +
              hash.keys.each { |k| k + 1 }
         | 
| 13 | 
            +
             | 
| 14 | 
            +
              # Return nil to avoid array creation penalty which may skew benchmark
         | 
| 15 | 
            +
              nil
         | 
| 16 | 
            +
            end
         | 
| 17 | 
            +
             | 
| 18 | 
            +
            # Good per Rubocop
         | 
| 19 | 
            +
            def hash_each_key(hash)
         | 
| 20 | 
            +
              hash.each_key { |k| k + 1 }
         | 
| 21 | 
            +
             | 
| 22 | 
            +
              # Return nil to avoid array creation penalty which may skew benchmark
         | 
| 23 | 
            +
              nil
         | 
| 24 | 
            +
            end
         | 
| 25 | 
            +
             | 
| 26 | 
            +
            [
         | 
| 27 | 
            +
              [],
         | 
| 28 | 
            +
              (1..5),
         | 
| 29 | 
            +
              (1..10),
         | 
| 30 | 
            +
              (1..20),
         | 
| 31 | 
            +
              (1..100),
         | 
| 32 | 
            +
              (1..500),
         | 
| 33 | 
            +
            ].each do |data|
         | 
| 34 | 
            +
              test_hash = data.zip(data).to_h
         | 
| 35 | 
            +
             | 
| 36 | 
            +
              section "Hash key enumeration (size=#{data.size})" do |bench|
         | 
| 37 | 
            +
                bench.report("Hash.keys.each") do
         | 
| 38 | 
            +
                  hash_keys_each(test_hash)
         | 
| 39 | 
            +
                end
         | 
| 40 | 
            +
             | 
| 41 | 
            +
                bench.report("Hash.each_key") do
         | 
| 42 | 
            +
                  hash_each_key(test_hash)
         | 
| 43 | 
            +
                end
         | 
| 44 | 
            +
              end
         | 
| 45 | 
            +
            end
         | 
| 46 | 
            +
             | 
| 47 | 
            +
            # Bad per Rubocop
         | 
| 48 | 
            +
            def hash_values_each(hash)
         | 
| 49 | 
            +
              hash.values.each { |v| v + 1 }
         | 
| 50 | 
            +
             | 
| 51 | 
            +
              # Return nil to avoid array creation penalty which may skew benchmark
         | 
| 52 | 
            +
              nil
         | 
| 53 | 
            +
            end
         | 
| 54 | 
            +
             | 
| 55 | 
            +
            # Good per Rubocop
         | 
| 56 | 
            +
            def hash_each_value(hash)
         | 
| 57 | 
            +
              hash.each_value { |v| v + 1 }
         | 
| 58 | 
            +
             | 
| 59 | 
            +
              # Return nil to avoid array creation penalty which may skew benchmark
         | 
| 60 | 
            +
              nil
         | 
| 61 | 
            +
            end
         | 
| 62 | 
            +
             | 
| 63 | 
            +
            [
         | 
| 64 | 
            +
              [],
         | 
| 65 | 
            +
              (1..5),
         | 
| 66 | 
            +
              (1..10),
         | 
| 67 | 
            +
              (1..20),
         | 
| 68 | 
            +
              (1..100),
         | 
| 69 | 
            +
              (1..500),
         | 
| 70 | 
            +
            ].each do |data|
         | 
| 71 | 
            +
              test_hash = data.zip(data).to_h
         | 
| 72 | 
            +
             | 
| 73 | 
            +
              section "Hash value enumeration (size=#{data.size})" do |bench|
         | 
| 74 | 
            +
                bench.report("Hash.values.each") do
         | 
| 75 | 
            +
                  hash_values_each(test_hash)
         | 
| 76 | 
            +
                end
         | 
| 77 | 
            +
             | 
| 78 | 
            +
                bench.report("Hash.each_value") do
         | 
| 79 | 
            +
                  hash_each_value(test_hash)
         | 
| 80 | 
            +
                end
         | 
| 81 | 
            +
              end
         | 
| 82 | 
            +
            end
         | 
| 83 | 
            +
             | 
| 84 | 
            +
            # rubocop:enable Style/HashEachMethods
         | 
| 85 | 
            +
             | 
| 86 | 
            +
            __END__
         | 
| 87 | 
            +
             | 
| 88 | 
            +
            ### Environment
         | 
| 89 | 
            +
             | 
| 90 | 
            +
            Heroku Performance-L Dyno
         | 
| 91 | 
            +
             | 
| 92 | 
            +
            ruby 2.7.3p183 (2021-04-05 revision 6847ee089d) [x86_64-linux]
         | 
| 93 | 
            +
            GC Disabled: false
         | 
| 94 | 
            +
             | 
| 95 | 
            +
            ### Test Cases
         | 
| 96 | 
            +
             | 
| 97 | 
            +
            Behavior for the keys and value enumerations is roughly equivalent. As
         | 
| 98 | 
            +
            hypothesized the `each_xyz` versions are faster. What is surprising is that the
         | 
| 99 | 
            +
            performance difference drops off drastically the larger the hash, even for
         | 
| 100 | 
            +
            small hash sizes. Basically, once the hash reaches 10 times, the performance
         | 
| 101 | 
            +
            gains are constant after that point (around 1 - 4%).
         | 
| 102 | 
            +
             | 
| 103 | 
            +
            #### Hash key enumeration (size=0)
         | 
| 104 | 
            +
             | 
| 105 | 
            +
            ```
         | 
| 106 | 
            +
            Warming up --------------------------------------
         | 
| 107 | 
            +
                  Hash.keys.each   913.942k i/100ms
         | 
| 108 | 
            +
                   Hash.each_key     1.376M i/100ms
         | 
| 109 | 
            +
            Calculating -------------------------------------
         | 
| 110 | 
            +
                  Hash.keys.each      9.167M (± 0.0%) i/s -     46.611M in   5.084564s
         | 
| 111 | 
            +
                   Hash.each_key     13.734M (± 0.2%) i/s -     68.779M in   5.008581s
         | 
| 112 | 
            +
                               with 95.0% confidence
         | 
| 113 | 
            +
             | 
| 114 | 
            +
            Comparison:
         | 
| 115 | 
            +
                   Hash.each_key: 13734476.7 i/s
         | 
| 116 | 
            +
                  Hash.keys.each:  9167168.9 i/s - 1.50x  (± 0.00) slower
         | 
| 117 | 
            +
                               with 95.0% confidence
         | 
| 118 | 
            +
            ```
         | 
| 119 | 
            +
             | 
| 120 | 
            +
            #### Hash key enumeration (size=5)
         | 
| 121 | 
            +
             | 
| 122 | 
            +
            ```
         | 
| 123 | 
            +
            Warming up --------------------------------------
         | 
| 124 | 
            +
                  Hash.keys.each   319.678k i/100ms
         | 
| 125 | 
            +
                   Hash.each_key   360.081k i/100ms
         | 
| 126 | 
            +
            Calculating -------------------------------------
         | 
| 127 | 
            +
                  Hash.keys.each      3.190M (± 0.4%) i/s -     15.984M in   5.012434s
         | 
| 128 | 
            +
                   Hash.each_key      3.596M (± 0.0%) i/s -     18.004M in   5.006636s
         | 
| 129 | 
            +
                               with 95.0% confidence
         | 
| 130 | 
            +
             | 
| 131 | 
            +
            Comparison:
         | 
| 132 | 
            +
                   Hash.each_key:  3596043.0 i/s
         | 
| 133 | 
            +
                  Hash.keys.each:  3189893.5 i/s - 1.13x  (± 0.00) slower
         | 
| 134 | 
            +
                               with 95.0% confidence
         | 
| 135 | 
            +
            ```
         | 
| 136 | 
            +
             | 
| 137 | 
            +
            #### Hash key enumeration (size=10)
         | 
| 138 | 
            +
             | 
| 139 | 
            +
            ```
         | 
| 140 | 
            +
            Warming up --------------------------------------
         | 
| 141 | 
            +
                  Hash.keys.each   201.546k i/100ms
         | 
| 142 | 
            +
                   Hash.each_key   209.461k i/100ms
         | 
| 143 | 
            +
            Calculating -------------------------------------
         | 
| 144 | 
            +
                  Hash.keys.each      2.019M (± 0.3%) i/s -     10.279M in   5.092727s
         | 
| 145 | 
            +
                   Hash.each_key      2.095M (± 0.0%) i/s -     10.683M in   5.099576s
         | 
| 146 | 
            +
                               with 95.0% confidence
         | 
| 147 | 
            +
             | 
| 148 | 
            +
            Comparison:
         | 
| 149 | 
            +
                   Hash.each_key:  2094785.3 i/s
         | 
| 150 | 
            +
                  Hash.keys.each:  2018768.6 i/s - 1.04x  (± 0.00) slower
         | 
| 151 | 
            +
                               with 95.0% confidence
         | 
| 152 | 
            +
            ```
         | 
| 153 | 
            +
             | 
| 154 | 
            +
            #### Hash key enumeration (size=20)
         | 
| 155 | 
            +
             | 
| 156 | 
            +
            ```
         | 
| 157 | 
            +
            Warming up --------------------------------------
         | 
| 158 | 
            +
                  Hash.keys.each   118.004k i/100ms
         | 
| 159 | 
            +
                   Hash.each_key   118.320k i/100ms
         | 
| 160 | 
            +
            Calculating -------------------------------------
         | 
| 161 | 
            +
                  Hash.keys.each      1.176M (± 0.4%) i/s -      5.900M in   5.021554s
         | 
| 162 | 
            +
                   Hash.each_key      1.182M (± 0.2%) i/s -      5.916M in   5.006809s
         | 
| 163 | 
            +
                               with 95.0% confidence
         | 
| 164 | 
            +
             | 
| 165 | 
            +
            Comparison:
         | 
| 166 | 
            +
                   Hash.each_key:  1181738.4 i/s
         | 
| 167 | 
            +
                  Hash.keys.each:  1175522.6 i/s - same-ish: difference falls within error
         | 
| 168 | 
            +
                               with 95.0% confidence
         | 
| 169 | 
            +
            ```
         | 
| 170 | 
            +
             | 
| 171 | 
            +
            #### Hash key enumeration (size=100)
         | 
| 172 | 
            +
             | 
| 173 | 
            +
            ```
         | 
| 174 | 
            +
            Warming up --------------------------------------
         | 
| 175 | 
            +
                  Hash.keys.each    27.217k i/100ms
         | 
| 176 | 
            +
                   Hash.each_key    26.138k i/100ms
         | 
| 177 | 
            +
            Calculating -------------------------------------
         | 
| 178 | 
            +
                  Hash.keys.each    272.497k (± 0.0%) i/s -      1.388M in   5.093882s
         | 
| 179 | 
            +
                   Hash.each_key    260.563k (± 0.4%) i/s -      1.307M in   5.017483s
         | 
| 180 | 
            +
                               with 95.0% confidence
         | 
| 181 | 
            +
             | 
| 182 | 
            +
            Comparison:
         | 
| 183 | 
            +
                  Hash.keys.each:   272497.2 i/s
         | 
| 184 | 
            +
                   Hash.each_key:   260563.2 i/s - 1.05x  (± 0.00) slower
         | 
| 185 | 
            +
                               with 95.0% confidence
         | 
| 186 | 
            +
            ```
         | 
| 187 | 
            +
             | 
| 188 | 
            +
            #### Hash key enumeration (size=500)
         | 
| 189 | 
            +
             | 
| 190 | 
            +
            ```
         | 
| 191 | 
            +
            Warming up --------------------------------------
         | 
| 192 | 
            +
                  Hash.keys.each     5.592k i/100ms
         | 
| 193 | 
            +
                   Hash.each_key     5.404k i/100ms
         | 
| 194 | 
            +
            Calculating -------------------------------------
         | 
| 195 | 
            +
                  Hash.keys.each     55.763k (± 0.2%) i/s -    279.600k in   5.014897s
         | 
| 196 | 
            +
                   Hash.each_key     54.060k (± 0.1%) i/s -    275.604k in   5.098253s
         | 
| 197 | 
            +
                               with 95.0% confidence
         | 
| 198 | 
            +
             | 
| 199 | 
            +
            Comparison:
         | 
| 200 | 
            +
                  Hash.keys.each:    55763.3 i/s
         | 
| 201 | 
            +
                   Hash.each_key:    54060.3 i/s - 1.03x  (± 0.00) slower
         | 
| 202 | 
            +
                               with 95.0% confidence
         | 
| 203 | 
            +
            ```
         | 
| 204 | 
            +
             | 
| 205 | 
            +
            #### Hash value enumeration (size=0)
         | 
| 206 | 
            +
             | 
| 207 | 
            +
            ```
         | 
| 208 | 
            +
            Warming up --------------------------------------
         | 
| 209 | 
            +
                Hash.values.each   922.361k i/100ms
         | 
| 210 | 
            +
                 Hash.each_value     1.372M i/100ms
         | 
| 211 | 
            +
            Calculating -------------------------------------
         | 
| 212 | 
            +
                Hash.values.each      9.229M (± 0.0%) i/s -     47.040M in   5.096857s
         | 
| 213 | 
            +
                 Hash.each_value     13.736M (± 0.0%) i/s -     69.983M in   5.094986s
         | 
| 214 | 
            +
                               with 95.0% confidence
         | 
| 215 | 
            +
             | 
| 216 | 
            +
            Comparison:
         | 
| 217 | 
            +
                 Hash.each_value: 13735592.7 i/s
         | 
| 218 | 
            +
                Hash.values.each:  9229287.5 i/s - 1.49x  (± 0.00) slower
         | 
| 219 | 
            +
                               with 95.0% confidence
         | 
| 220 | 
            +
            ```
         | 
| 221 | 
            +
             | 
| 222 | 
            +
            #### Hash value enumeration (size=5)
         | 
| 223 | 
            +
             | 
| 224 | 
            +
            ```
         | 
| 225 | 
            +
            Warming up --------------------------------------
         | 
| 226 | 
            +
                Hash.values.each   317.174k i/100ms
         | 
| 227 | 
            +
                 Hash.each_value   358.507k i/100ms
         | 
| 228 | 
            +
            Calculating -------------------------------------
         | 
| 229 | 
            +
                Hash.values.each      3.190M (± 0.0%) i/s -     16.176M in   5.071511s
         | 
| 230 | 
            +
                 Hash.each_value      3.582M (± 0.0%) i/s -     17.925M in   5.004607s
         | 
| 231 | 
            +
                               with 95.0% confidence
         | 
| 232 | 
            +
             | 
| 233 | 
            +
            Comparison:
         | 
| 234 | 
            +
                 Hash.each_value:  3581759.4 i/s
         | 
| 235 | 
            +
                Hash.values.each:  3189555.5 i/s - 1.12x  (± 0.00) slower
         | 
| 236 | 
            +
                               with 95.0% confidence
         | 
| 237 | 
            +
            ```
         | 
| 238 | 
            +
             | 
| 239 | 
            +
            #### Hash value enumeration (size=10)
         | 
| 240 | 
            +
             | 
| 241 | 
            +
            ```
         | 
| 242 | 
            +
            Warming up --------------------------------------
         | 
| 243 | 
            +
                Hash.values.each   201.766k i/100ms
         | 
| 244 | 
            +
                 Hash.each_value   209.128k i/100ms
         | 
| 245 | 
            +
            Calculating -------------------------------------
         | 
| 246 | 
            +
                Hash.values.each      2.032M (± 0.0%) i/s -     10.290M in   5.065224s
         | 
| 247 | 
            +
                 Hash.each_value      2.093M (± 0.0%) i/s -     10.666M in   5.096053s
         | 
| 248 | 
            +
                               with 95.0% confidence
         | 
| 249 | 
            +
             | 
| 250 | 
            +
            Comparison:
         | 
| 251 | 
            +
                 Hash.each_value:  2092905.3 i/s
         | 
| 252 | 
            +
                Hash.values.each:  2031517.4 i/s - 1.03x  (± 0.00) slower
         | 
| 253 | 
            +
                               with 95.0% confidence
         | 
| 254 | 
            +
            ```
         | 
| 255 | 
            +
             | 
| 256 | 
            +
            #### Hash value enumeration (size=20)
         | 
| 257 | 
            +
             | 
| 258 | 
            +
            ```
         | 
| 259 | 
            +
            Warming up --------------------------------------
         | 
| 260 | 
            +
                Hash.values.each   117.255k i/100ms
         | 
| 261 | 
            +
                 Hash.each_value   117.577k i/100ms
         | 
| 262 | 
            +
            Calculating -------------------------------------
         | 
| 263 | 
            +
                Hash.values.each      1.182M (± 0.1%) i/s -      5.980M in   5.058729s
         | 
| 264 | 
            +
                 Hash.each_value      1.176M (± 0.0%) i/s -      5.996M in   5.098809s
         | 
| 265 | 
            +
                               with 95.0% confidence
         | 
| 266 | 
            +
             | 
| 267 | 
            +
            Comparison:
         | 
| 268 | 
            +
                Hash.values.each:  1182126.7 i/s
         | 
| 269 | 
            +
                 Hash.each_value:  1176047.5 i/s - 1.01x  (± 0.00) slower
         | 
| 270 | 
            +
                               with 95.0% confidence
         | 
| 271 | 
            +
            ```
         | 
| 272 | 
            +
             | 
| 273 | 
            +
            #### Hash value enumeration (size=100)
         | 
| 274 | 
            +
             | 
| 275 | 
            +
            ```
         | 
| 276 | 
            +
            Warming up --------------------------------------
         | 
| 277 | 
            +
                Hash.values.each    27.263k i/100ms
         | 
| 278 | 
            +
                 Hash.each_value    26.208k i/100ms
         | 
| 279 | 
            +
            Calculating -------------------------------------
         | 
| 280 | 
            +
                Hash.values.each    275.209k (± 0.0%) i/s -      1.390M in   5.052242s
         | 
| 281 | 
            +
                 Hash.each_value    261.696k (± 0.0%) i/s -      1.310M in   5.007358s
         | 
| 282 | 
            +
                               with 95.0% confidence
         | 
| 283 | 
            +
             | 
| 284 | 
            +
            Comparison:
         | 
| 285 | 
            +
                Hash.values.each:   275209.0 i/s
         | 
| 286 | 
            +
                 Hash.each_value:   261696.2 i/s - 1.05x  (± 0.00) slower
         | 
| 287 | 
            +
                               with 95.0% confidence
         | 
| 288 | 
            +
            ```
         | 
| 289 | 
            +
             | 
| 290 | 
            +
            #### Hash value enumeration (size=500)
         | 
| 291 | 
            +
             | 
| 292 | 
            +
            ```
         | 
| 293 | 
            +
            Warming up --------------------------------------
         | 
| 294 | 
            +
                Hash.values.each     5.586k i/100ms
         | 
| 295 | 
            +
                 Hash.each_value     5.408k i/100ms
         | 
| 296 | 
            +
            Calculating -------------------------------------
         | 
| 297 | 
            +
                Hash.values.each     56.245k (± 0.2%) i/s -    284.886k in   5.066190s
         | 
| 298 | 
            +
                 Hash.each_value     54.104k (± 0.0%) i/s -    275.808k in   5.097780s
         | 
| 299 | 
            +
                               with 95.0% confidence
         | 
| 300 | 
            +
             | 
| 301 | 
            +
            Comparison:
         | 
| 302 | 
            +
                Hash.values.each:    56244.5 i/s
         | 
| 303 | 
            +
                 Hash.each_value:    54104.0 i/s - 1.04x  (± 0.00) slower
         | 
| 304 | 
            +
                               with 95.0% confidence
         | 
| 305 | 
            +
            ```
         |