File: Rakefile

package info (click to toggle)
ruby-enumerable-statistics 2.0.7%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 1,132 kB
  • sloc: ruby: 2,220; ansic: 1,921; javascript: 408; makefile: 8; sh: 4
file content (31 lines) | stat: -rw-r--r-- 597 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
require "bundler/gem_tasks"
require "rake/extensiontask"
require "rspec/core/rake_task"

task :default => :spec

Rake::ExtensionTask.new('enumerable/statistics/extension')

directory 'lib/enumerable/statistics'

desc "Run test"
task :test do
  ruby("test/run-test.rb")
end
task :test => :compile

RSpec::Core::RakeTask.new(:spec)
task :spec => :compile

task :bench do
  puts "# sum\n"
  system('benchmark-driver bench/sum.yml')

  puts "# mean\n"
  system('benchmark-driver bench/mean.yml')

  puts "# variance\n"
  system('benchmark-driver bench/variance.yml')
end

task default: [:test, :spec]