Sha256: c5dc8e2bb839f7204baffd94b7b7be316a592ec34bcdcd58cdfcf0f7ebf1d3df

Contents?: true

Size: 1017 Bytes

Versions: 27

Compression:

Stored size: 1017 Bytes

Contents

require 'bundler/gem_tasks'

desc 'Run library from within a Pry console'
task :console do
  require 'pry'
  require 'fastly'
  ARGV.clear
  Pry.start
end

namespace :clean do
  desc 'Remove all trailing whitespace from Ruby files in lib and test'
  task :whitespace do
    sh "find {test,lib,bin} -name *.rb -exec sed -i '' 's/[ ]*$//' {} \\\;"
  end
end

require 'rubocop/rake_task'

desc 'Run rubocop'
RuboCop::RakeTask.new(:rubocop) do |task|
  task.patterns = ['bin/*', 'lib/**/*.rb', 'test/**/*.rb']
  task.formatters = ['fuubar']
  task.fail_on_error = true
end

require 'rdoc/task'

RDoc::Task.new do |rdoc|
  rdoc.rdoc_dir = 'doc'
  rdoc.main = 'README.md'
  rdoc.rdoc_files.include('README.md', 'lib/**/*.rb')
end

namespace :test do
  desc 'Run all unit tests'
  task :unit do
    sh 'bundle exec ruby -Itest -Ilib test/fastly/*_test.rb'
  end
end

require 'rake/testtask'

Rake::TestTask.new do |t|
  t.libs << 'test'
  t.test_files = FileList['test/*test.rb']
  t.verbose = true
end

task default: :test

Version data entries

27 entries across 27 versions & 1 rubygems

Version Path
fastly-2.0.0 Rakefile
fastly-1.15.0 Rakefile
fastly-1.14.0 Rakefile
fastly-1.13.2 Rakefile
fastly-1.13.1 Rakefile
fastly-1.13.0 Rakefile
fastly-1.12.0 Rakefile
fastly-1.11.0 Rakefile
fastly-1.10.0 Rakefile
fastly-1.9.0 Rakefile
fastly-1.8.0 Rakefile
fastly-1.7.0 Rakefile
fastly-1.6.1 Rakefile
fastly-1.6.0 Rakefile
fastly-1.5.0 Rakefile
fastly-1.4.3 Rakefile
fastly-1.4.2 Rakefile
fastly-1.4.1 Rakefile
fastly-1.4.0 Rakefile
fastly-1.3.0 Rakefile