Sha256: be1930101cfe857bde941fe36241155c3b2961429493a50a76fe2fd4505573fc
Contents?: true
Size: 1.53 KB
Versions: 34
Compression:
Stored size: 1.53 KB
Contents
require "high_five" require 'high_five/thor/runner' require 'high_five/thor/tasks' # This file was generated by the `rspec --init` command. Conventionally, all # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`. # Require this file using `require "spec_helper"` to ensure that it is only # loaded once. # # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration RSpec.configure do |config| config.treat_symbols_as_metadata_keys_with_true_values = true config.run_all_when_everything_filtered = true config.filter_run :focus # Run specs in random order to surface order dependencies. If you find an # order dependency and want to debug it, you can fix the order by providing # the seed, which is printed after each run. # --seed 1234 config.order = 'random' end RSpec::Matchers.define :exist do match do |actual| File.exists?(actual) end end module HighFive::TestHelper def create_dummy_app! @original_dir = Dir.pwd @project_root = Dir.mktmpdir("hi5") Dir.chdir @project_root FileUtils.cp_r(Dir[File.join(File.dirname(__FILE__), "dummy", "*")], @project_root) end def cli(task_class, options={environment: 'development'}) cli = task_class.new([], options) cli.instance_variable_set("@base_config", HighFive::Config.instance) cli end def destroy_dummy_app! puts "Cleaning up deploy directory. Contents: " system("find #{@project_root} -print | sed 's;[^/]*/;|___;g;s;___|; |;g'") Dir.chdir @original_dir FileUtils.rm_rf @project_root end end
Version data entries
34 entries across 34 versions & 1 rubygems