Sha256: eb242e7d07e1e38674e27826a53a1e80f2909d87499cef382d06eb5feca7da1e
Contents?: true
Size: 1.48 KB
Versions: 9
Compression:
Stored size: 1.48 KB
Contents
#!/usr/bin/env ruby # encoding: UTF-8 $: << File.dirname(__FILE__) + '/../lib' $: << File.dirname(__FILE__) + '/../../cucumber-ruby-core/lib' require 'cucumber/platform' module Cucumber features_glob = ARGV[0] || 'features/**/*.feature' feature_files = Dir[features_glob].reject { |f| f =~ /iso-8859-1/ } puts "Running features:" p feature_files require 'cucumber/core' extend Cucumber::Core require 'cucumber/core/gherkin/document' features = feature_files.map do |file| Cucumber::Core::Gherkin::Document.new(file, File.read(file)) end require 'cucumber/mappings' mappings = Mappings.new require 'cucumber/formatter/report_adapter' require 'cucumber/formatter/progress' require 'cucumber/formatter/pretty' formatter_options = { skip_profile_information: true, source: true, } formatter = Cucumber::Formatter::Pretty.new(mappings.runtime, STDOUT, formatter_options) report = Cucumber::Formatter::ReportAdapter.new(mappings.runtime, formatter) DebugReport = Class.new do def before_test_case(test_case) puts puts test_case.inspect end def after_test_case(test_case, result) end def before_test_step(test_step) puts ' ' + test_step.inspect end def after_test_step(test_step, result) end def after_suite end end #report = DebugReport.new require 'cucumber/core/test/tag_filter' execute features, mappings, report, [[Cucumber::Core::Test::TagFilter, ['~@jruby']]] report.after_suite end
Version data entries
9 entries across 9 versions & 1 rubygems