Sha256: 34efb0c1567cba17aaa9e179650c5c6f0c6dc4fc6a9e9bdf490aadd43597c223
Contents?: true
Size: 1 KB
Versions: 1
Compression:
Stored size: 1 KB
Contents
#!/usr/bin/env ruby lib = File.dirname(__FILE__) + '/../lib' $:.unshift lib unless $:.include? lib require 'cuukie/cli' include Cuukie::Cli options = parse_options ARGV exit if options.empty? server_command = "ruby #{File.dirname(__FILE__)}/../lib/cuukie/server.rb #{options[:cuukieport]}" if options[:server] system server_command exit else Process.detach(fork { system "#{server_command} >/dev/null 2>&1" }) end unless options[:keepserver] at_exit do require 'rest-client' begin RestClient.delete "http://localhost:#{options[:cuukieport]}" rescue; end end end if options[:showpage] require 'launchy' Launchy.open("http://localhost:#{options[:cuukieport]}") else puts "View your features at http://localhost:#{options[:cuukieport]}" end # TODO: auto-require formatter (warning: if you tell Cucumber to --require # something, it will want to --require everything!) system "cucumber #{ARGV.join(' ')} --format cuukie" unless options[:nowait] puts 'Press a key to exit' gets end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
cuukie-0.2.0 | bin/cuukie |