Sha256: 82a33f1f3512ceee76fcc6c6ee2eada313ea8da84281d719ef2a866627d24006

Contents?: true

Size: 522 Bytes

Versions: 1

Compression:

Stored size: 522 Bytes

Contents

module Jeka

  class TestSet
    def initialize(folder)
      @folder = folder
      _load
    end
    
    def _load
      tests_dir = Dir.new(@folder)
      @input = []
      @output = []
      tests_dir.each do |test|
        @input << File.join(@folder, test) if test.include?(".input")
        @output << File.join(@folder, test) if test.include?(".output")
      end
    end
    
    def each
      @test = []
      @input.each_with_index do |input, i|
        yield input, @output[i]
      end
    end
  end
  
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
jeka-0.1.0 lib/jeka/test_set.rb