Sha256: a70281c9a426f2ccb08df96be87ba4d664caf62bc7dee163d4817771a8a81c3c

Contents?: true

Size: 703 Bytes

Versions: 5

Compression:

Stored size: 703 Bytes

Contents

module ActiveMocker

  class << self

    # Method will be deprecated in v2
    def mock(model_name, options=nil)
      Generate.mock(model_name)
    end

    # Override default Configurations
    #
    #  ActiveMocker::Generate.configure do |config|
    #    config.schema_file = File.join(Rails.root, 'db/schema.rb')
    #    config.model_dir   = File.join(Rails.root, 'app/models')
    #    config.mock_dir    = File.join(Rails.root, 'spec/mocks')
    #    config.logger      = Rails.logger
    #  end
    #
    def configure(&block)
      Generate.configure(&block)
    end

    alias_method :config, :configure

    # Generates Mocks file
    def create_mocks
      Generate.new
    end

  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
active_mocker-1.6.4 lib/active_mocker/public_methods.rb
active_mocker-1.6.3 lib/active_mocker/public_methods.rb
active_mocker-1.6.2 lib/active_mocker/public_methods.rb
active_mocker-1.6.1 lib/active_mocker/public_methods.rb
active_mocker-1.6 lib/active_mocker/public_methods.rb