Sha256: 189031d1101ff149ab58686d8433f94048449cb61edfb2463c3e1d0fb223204f

Contents?: true

Size: 492 Bytes

Versions: 13

Compression:

Stored size: 492 Bytes

Contents

require 'rake'
require 'rake/tasklib'
require 'service_mock/server'

module ServiceMock
  module Rake
    class BaseTask < ::Rake::TaskLib
      include ::Rake::DSL if defined?(::Rake::DSL)

      attr_reader :name, :server

      def initialize(name, wiremock_version, working_directory='config/mocks')
        @name = name
        @server = ::ServiceMock::Server.new(wiremock_version, working_directory)
        yield server if block_given?
        define_task
      end

    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
service_mock-0.9 lib/service_mock/rake/base_task.rb
service_mock-0.8 lib/service_mock/rake/base_task.rb
service_mock-0.7.1 lib/service_mock/rake/base_task.rb
service_mock-0.7 lib/service_mock/rake/base_task.rb
service_mock-0.6 lib/service_mock/rake/base_task.rb
service_mock-0.5.2 lib/service_mock/rake/base_task.rb
service_mock-0.5.1 lib/service_mock/rake/base_task.rb
service_mock-0.5 lib/service_mock/rake/base_task.rb
service_mock-0.4 lib/service_mock/rake/base_task.rb
service_mock-0.3.1 lib/service_mock/rake/base_task.rb
service_mock-0.3 lib/service_mock/rake/base_task.rb
service_mock-0.2 lib/service_mock/rake/base_task.rb
service_mock-0.1 lib/service_mock/rake/base_task.rb