Sha256: 5151a87f8f6df8a6e55c39f3cc0f167dec54bca156fb9a7ebe9c86a1a4de80f9
Contents?: true
Size: 1.34 KB
Versions: 2
Compression:
Stored size: 1.34 KB
Contents
require "baleen/task/task" module Baleen module Task class Cucumber < Baleen::Task::Base include Serializable include Baleen::Default attr_reader :target_files def initialize(opt) super() @params[:shell] = opt[:shell] || "/bin/bash" @params[:opt] = opt[:opt] || "-c" @params[:exe] = opt[:exe] || "bundle exec cucumber" @params[:work_dir] = opt[:work_dir] || default_work_dir @params[:files] = opt[:files] || default_features @params[:concurrency] = opt[:concurrency] || default_concurrency @params[:before_command] = opt[:before_command] || default_before_command @params[:image] = opt[:image] @params[:command] = opt[:command] @params[:results] = opt[:results] @params[:status] = opt[:status] @params[:commit] = nil end def prepare task = Generic.new( shell: shell, opt: opt, work_dir: work_dir, image: image, command: %{find #{files} | grep "\\.feature"} ) runner = Baleen::Runner.new(task) result = runner.run @target_files = result[:log].split("\n") end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
baleen-0.2.0 | lib/baleen/task/cucumber.rb |
baleen-0.1.2 | lib/baleen/task/cucumber.rb |