Sha256: fa65e0a5a417c5059ab4e776904a9c15a0a1959da75ec28732349692c3ef8076

Contents?: true

Size: 1.08 KB

Versions: 25

Compression:

Stored size: 1.08 KB

Contents

require 'rake'
require 'spec_helper'
require 'speckle/list/builder'
require 'speckle/list/absolute_path_transformer'
require 'speckle/list/dir_expander'
require 'speckle/list/extension_transformer'
require 'speckle/list/file_content_filter'
require 'speckle/list/pattern_filter'
require 'securerandom'

module Speckle
  module List

    describe 'Builder' do

      before :each do 
        @builder = Builder.new
      end

      it 'can be built' do
        expect(@builder).to respond_to(:build)
      end

      it 'can build list of source files from directory', :a => true do
        builder = Builder.new
        builder.add_source 'spec'
        builder.add_filter DirExpander.new('**/*_spec.riml')
        builder.add_filter FileContentFilter.new('class', false)
        builder.add_filter PatternFilter.new('matcher')
        builder.add_filter AbsolutePathTransformer.new
        builder.add_filter ExtensionTransformer.new('riml')

        result = builder.build
        result.each do |f|
          expect(File.exists?(f)).to be_true
        end
        #puts result
      end

    end

  end
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
speckle-0.2.0 spec/speckle/list/builder_spec.rb
speckle-0.1.31 spec/speckle/list/builder_spec.rb
speckle-0.1.30 spec/speckle/list/builder_spec.rb
speckle-0.1.29 spec/speckle/list/builder_spec.rb
speckle-0.1.28 spec/speckle/list/builder_spec.rb
speckle-0.1.27 spec/speckle/list/builder_spec.rb
speckle-0.1.26 spec/speckle/list/builder_spec.rb
speckle-0.1.25 spec/speckle/list/builder_spec.rb
speckle-0.1.24 spec/speckle/list/builder_spec.rb
speckle-0.1.23 spec/speckle/list/builder_spec.rb
speckle-0.1.22 spec/speckle/list/builder_spec.rb
speckle-0.1.21 spec/speckle/list/builder_spec.rb
speckle-0.1.20 spec/speckle/list/builder_spec.rb
speckle-0.1.19 spec/speckle/list/builder_spec.rb
speckle-0.1.18 spec/speckle/list/builder_spec.rb
speckle-0.1.17 spec/speckle/list/builder_spec.rb
speckle-0.1.16 spec/speckle/list/builder_spec.rb
speckle-0.1.15 spec/speckle/list/builder_spec.rb
speckle-0.1.14 spec/speckle/list/builder_spec.rb
speckle-0.1.13 spec/speckle/list/builder_spec.rb