-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRakefile
More file actions
31 lines (25 loc) · 939 Bytes
/
Rakefile
File metadata and controls
31 lines (25 loc) · 939 Bytes
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 'rspec/core/rake_task'
#para no tener que poner -Ilib
$:.unshift File.dirname(__FILE__) + 'lib'
#-------------------------------------------------------------------------------
task :default => :spec
#-------------------------------------------------------------------------------
desc "Ejecutar tests"
task :spec do
sh "rspec spec/tictactoe_spec.rb --format documentation"
end
#-------------------------------------------------------------------------------
desc "Ejecutar una partida del juego"
task :bin do
sh "ruby -Ilib bin/game.rb"
end
#-------------------------------------------------------------------------------
desc "Ejecutar test con formato html"
task :thtml do
sh "rspec spec/tictactoe_spec.rb --format html > resultados.html"
end
#-------------------------------------------------------------------------------
task :test do
sh "ruby -w -Ilib test/tc_tictactoe.rb"
end