Sha256: 8dba2270e426433daeb2a4a4337cab0f77d9d5e628c8f0cd03b020b4717fb4fc

Contents?: true

Size: 795 Bytes

Versions: 6

Compression:

Stored size: 795 Bytes

Contents

require 'rake/tasklib'

Dir["#{File.dirname(__FILE__)}/side_by_side_specs_support/*.rb"].each do |path|
  require path
end

module Rake::Funnel::Tasks
  class SideBySideSpecs < Rake::TaskLib
    attr_accessor :name, :projects, :references, :specs, :enabled

    def initialize(name = :compile)
      @name = name

      @projects = %w(**/*.csproj **/*.vbproj **/*.fsproj)
      @references = []
      @specs = %w(*Specs.cs **/*Specs.cs *Tests.cs **/*Tests.cs)
      @enabled = false

      yield self if block_given?
      define
    end

    private
    def define
      task name do
        next unless enabled
        SideBySideSpecsSupport::Remover.remove({ projects: projects, references: references, specs: specs })
      end

      self
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
rake-funnel-0.0.6.pre lib/rake/funnel/tasks/side_by_side_specs.rb
rake-funnel-0.0.5.pre lib/rake/funnel/tasks/side_by_side_specs.rb
rake-funnel-0.0.4.pre lib/rake/funnel/tasks/side_by_side_specs.rb
rake-funnel-0.0.3.pre lib/rake/funnel/tasks/side_by_side_specs.rb
rake-funnel-0.0.2.pre lib/rake/funnel/tasks/side_by_side_specs.rb
rake-funnel-0.0.1.pre lib/rake/funnel/tasks/side_by_side_specs.rb