Sha256: dba205bb01be47d19fb93bd62932660be7f28aed26f282523f81595146192e67

Contents?: true

Size: 571 Bytes

Versions: 31

Compression:

Stored size: 571 Bytes

Contents

# frozen_string_literal: true
module ActiveMocker
  module TemplateMethods
    def self.included(base)
      base.extend(ClassMethods)
    end

    module ClassMethods
      def attributes
        HashWithIndifferentAccess.new({})
      end

      def types
        HashProcess.new({}, method(:build_type))
      end

      def associations
        {}
      end

      def associations_by_class
        {}
      end

      def mocked_class
        ""
      end

      def attribute_names
        []
      end

      def primary_key
        ""
      end
    end
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
active_mocker-2.6.2 lib/active_mocker/mock/template_methods.rb
active_mocker-2.6.1.beta2 lib/active_mocker/mock/template_methods.rb
active_mocker-2.6.1.beta lib/active_mocker/mock/template_methods.rb
active_mocker-2.6.0 lib/active_mocker/mock/template_methods.rb
active_mocker-2.5.4 lib/active_mocker/mock/template_methods.rb
active_mocker-2.5.3 lib/active_mocker/mock/template_methods.rb
active_mocker-2.5.2 lib/active_mocker/mock/template_methods.rb
active_mocker-2.5.1 lib/active_mocker/mock/template_methods.rb
active_mocker-2.5.1.pre lib/active_mocker/mock/template_methods.rb
active_mocker-2.5.0 lib/active_mocker/mock/template_methods.rb
active_mocker-2.4.4 lib/active_mocker/mock/template_methods.rb
active_mocker-2.4.3 lib/active_mocker/mock/template_methods.rb
active_mocker-2.4.2 lib/active_mocker/mock/template_methods.rb
active_mocker-2.4.1 lib/active_mocker/mock/template_methods.rb
active_mocker-2.4.0 lib/active_mocker/mock/template_methods.rb
active_mocker-2.4.0.pre5 lib/active_mocker/mock/template_methods.rb
active_mocker-2.3.4 lib/active_mocker/mock/template_methods.rb
active_mocker-2.4.0.pre4 lib/active_mocker/mock/template_methods.rb
active_mocker-2.4.0.pre3 lib/active_mocker/mock/template_methods.rb
active_mocker-2.4.0.pre2 lib/active_mocker/mock/template_methods.rb