Sha256: 547b4bcb283099857a9cea367f45ffa61c281719372c893baeda51c361d72aff
Contents?: true
Size: 1.35 KB
Versions: 1
Compression:
Stored size: 1.35 KB
Contents
# frozen_string_literal: true require_relative 'lib/ruby_raider' require_relative 'lib/commands/scaffolding_commands' require_relative 'lib/utilities/logger' desc 'Creates a new test project' task :new, [:name] do |_t, args| system "bin/raider -n #{args.name}" end desc 'Creates a page' task :page, [:name, :path] do |_t, args| ScaffoldingCommands.new.invoke(:page, nil, %W[:#{args.name} --path #{args.path}]) end desc 'Sets a browser' task :browser, [:type, :options] do |_t, args| ScaffoldingCommands.new.invoke(:browser, nil, %W[:#{args.type} --opts #{args.options}]) end desc 'Updates a path' task :path, [:path] do |_t, args| ScaffoldingCommands.new.invoke(:path, nil, %W[#{args.path} -s]) end desc 'Logs a warning' task :log, [:message] do |_t, args| RubyRaider::Logger.warn(args.message) end desc 'Runs integration tests' task :integration, [:type, :name] do |_t, args| path = args.type ? "spec/integration/#{args.type}" : 'spec/integration' full_path = if args.type == 'generators' && args.name "#{path}/#{args.name.downcase}_generator_spec.rb" elsif args.type == 'commands' && args.name "#{path}/#{args.name.downcase}_commands_spec.rb" else path end system "rspec #{full_path}" end desc 'Runs system tests' task :system do |_t| system 'rspec spec/system' end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ruby_raider-0.8.9 | Rakefile |