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: ineffective_access_modifier_spec.rb
    path of file: ./repos/rubocop/spec/rubocop/cop/lint
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

RSpec.describe RuboCop::Cop::Lint::IneffectiveAccessModifier, :config do
  context 'when `private` is applied to a class method' do
    it 'registers an offense' do
      expect_off
    
            def self.method2
            ^^^ `private` (on line 2) does not make singleton methods private. Use `private_class_method` or `private` inside a `class << self` block instead.
              puts "hi"
            end

            private_class_method :method
          end