Sha256: 71f1950a6221a845470da5ce8e89be91d24006888c7b675a2db6bad83634d4f9
Contents?: true
Size: 767 Bytes
Versions: 2
Compression:
Stored size: 767 Bytes
Contents
require 'bundler/setup' require 'cuukie' require 'cuukie/client' include Cuukie::Client def start_process(command) Process.detach fork { exec command } end def run_cucumber(feature = '') system "cd spec/test_project && cucumber features/#{feature} \ --require ../../lib/cuukie \ --require features \ --format Cuukie::Formatter" end require 'rest-client' [:GET, :POST, :PUT, :DELETE].each do |method| Kernel.send :define_method, method do |*args| args[0] = "http://localhost:4569#{args[0]}" RestClient.send method.to_s.downcase, *args end end def html GET('/').body end def start_server start_process "ruby bin/cuukie --server >/dev/null 2>&1" wait_for_server_at 4569 end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
cuukie-0.3.1 | spec/spec_helper.rb |
cuukie-0.3.0 | spec/spec_helper.rb |