You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: method_def_parentheses_spec.rb
    path of file: ./repos/rubocop/spec/rubocop/cop/style
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

RSpec.describe RuboCop::Cop::Style::MethodDefParentheses, :config do
  shared_examples 'no parentheses' do
    # common to require_no_parentheses and
    # require_no_parentheses_except_multiline
    it 'reports an offense for def with parameters with parens' do
      expect_offense(<<~RUBY)
        def func(a, b)
                ^^^^^^ Use def without parentheses.
        end
      RUBY

      expect_correction(<<~RUBY)
        def func a, b
        end
      RUBY
    end

    it 'accepts a def with parameters but no parens' do
      expect_no_offenses(<<~RUBY)
        def func a, b
        end
      RUBY
    end

    it 'reports an offe
    
        def self.test(param); end
                     ^^^^^^^ Use def without parentheses.
      RUBY

      expect_correction(<<~RUBY)
        def self.test param; end
      RUBY
    end

    it 'requires parens for forwarding', :ruby27 do
      expect_no_offenses(<<~RUBY)
        def foo(...)
          bar(...)
        end
      RUBY
    end

    it 'requires parens for anonymous block forwarding', :ruby31 do
      expect_no_offenses(<<~RUBY)
        def foo(&)
          bar(&)
        end
      RUBY
    end

    it 'requires parens for anonymous rest arguments forwarding', :ruby32 do
      expect_no_offenses(<<~RUBY)
        def foo(*)
          bar(*)
        end
      RUBY
    end

    it 'requires parens for anonymous keyword rest arguments forwarding', :ruby32 do
      expect_no_offenses(<<~RUBY)
        def foo(**)
          bar(**)
        end
      RUBY
    end
  end