Sha256: 1f275ca9bdcd629138c0d6f53965e2585a3d541af62569686b5db8b5432191f0

Contents?: true

Size: 507 Bytes

Versions: 44

Compression:

Stored size: 507 Bytes

Contents

# frozen_string_literal: true

module RuboCop
  module RSpec
    # Wrapper for RSpec DSL methods
    class Concept
      include Language
      include Language::NodePattern
      extend NodePattern::Macros

      def initialize(node)
        @node = node
      end

      def eql?(other)
        node == other.node
      end

      alias == eql?

      def hash
        [self.class, node].hash
      end

      def to_node
        node
      end

      protected

      attr_reader :node
    end
  end
end

Version data entries

44 entries across 44 versions & 1 rubygems

Version Path
rubocop-rspec-1.31.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.30.1 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.30.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.29.1 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.29.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.28.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.27.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.26.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.25.1 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.25.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.24.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.23.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.22.2 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.22.1 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.22.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.21.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.20.1 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.20.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.19.0 lib/rubocop/rspec/concept.rb
rubocop-rspec-1.18.0 lib/rubocop/rspec/concept.rb