Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: ryanb/ruby-warrior
base: fdc79340a9
...
head fork: ryanb/ruby-warrior
compare: fbbaf027d1
  • 7 commits
  • 45 files changed
  • 0 commit comments
  • 4 contributors
Showing with 55 additions and 57 deletions.
  1. +3 −0  .gitignore
  2. +1 −1  Gemfile
  3. +4 −9 Rakefile
  4. +5 −5 features/step_definitions/interaction_steps.rb
  5. +1 −1  features/support/env.rb
  6. +1 −1  spec/ruby_warrior/abilities/attack_spec.rb
  7. +1 −1  spec/ruby_warrior/abilities/base_spec.rb
  8. +1 −1  spec/ruby_warrior/abilities/bind_spec.rb
  9. +1 −1  spec/ruby_warrior/abilities/direction_of_spec.rb
  10. +1 −1  spec/ruby_warrior/abilities/direction_of_stairs_spec.rb
  11. +1 −1  spec/ruby_warrior/abilities/distance_of_spec.rb
  12. +1 −1  spec/ruby_warrior/abilities/explode_spec.rb
  13. +1 −1  spec/ruby_warrior/abilities/feel_spec.rb
  14. +1 −1  spec/ruby_warrior/abilities/form_spec.rb
  15. +1 −1  spec/ruby_warrior/abilities/health_spec.rb
  16. +1 −1  spec/ruby_warrior/abilities/listen_spec.rb
  17. +1 −1  spec/ruby_warrior/abilities/look_spec.rb
  18. +1 −1  spec/ruby_warrior/abilities/pivot_spec.rb
  19. +1 −1  spec/ruby_warrior/abilities/rescue_spec.rb
  20. +1 −1  spec/ruby_warrior/abilities/rest_spec.rb
  21. +1 −1  spec/ruby_warrior/abilities/shoot_spec.rb
  22. +1 −1  spec/ruby_warrior/abilities/throw_spec.rb
  23. +1 −1  spec/ruby_warrior/abilities/walk_spec.rb
  24. +1 −1  spec/ruby_warrior/core_additions_spec.rb
  25. +1 −1  spec/ruby_warrior/floor_spec.rb
  26. +1 −1  spec/ruby_warrior/game_spec.rb
  27. +1 −1  spec/ruby_warrior/level_loader_spec.rb
  28. +1 −1  spec/ruby_warrior/level_spec.rb
  29. +1 −1  spec/ruby_warrior/player_generator_spec.rb
  30. +1 −1  spec/ruby_warrior/position_spec.rb
  31. +1 −1  spec/ruby_warrior/profile_spec.rb
  32. +1 −1  spec/ruby_warrior/space_spec.rb
  33. +1 −1  spec/ruby_warrior/tower_spec.rb
  34. +1 −1  spec/ruby_warrior/turn_spec.rb
  35. +1 −1  spec/ruby_warrior/ui_spec.rb
  36. +1 −1  spec/ruby_warrior/units/archer_spec.rb
  37. +1 −1  spec/ruby_warrior/units/base_spec.rb
  38. +1 −1  spec/ruby_warrior/units/captive_spec.rb
  39. +1 −1  spec/ruby_warrior/units/golem_spec.rb
  40. +1 −1  spec/ruby_warrior/units/sludge_spec.rb
  41. +1 −1  spec/ruby_warrior/units/thick_sludge_spec.rb
  42. +1 −1  spec/ruby_warrior/units/warrior_spec.rb
  43. +1 −1  spec/ruby_warrior/units/wizard_spec.rb
  44. +2 −2 spec/spec_helper.rb
  45. +1 −1  towers/intermediate/level_003.rb
View
3  .gitignore
@@ -1,2 +1,5 @@
tmp/**/*
*.gem
+.project
+.buildpath
+Gemfile.lock
View
2  Gemfile
@@ -2,7 +2,7 @@ source :rubygems
group :test do
gem 'rake'
- gem 'rspec', '~> 1.3.2'
+ gem 'rspec', '~> 2.8.0'
gem 'cucumber'
gem 'mocha'
end
View
13 Rakefile
@@ -1,17 +1,12 @@
require 'rake'
-require 'spec'
+require 'rspec'
+require 'rspec/core/rake_task'
require 'cucumber'
-
require 'cucumber/rake/task'
-require 'spec/rake/spectask'
-
-
-spec_files = Rake::FileList["spec/**/*_spec.rb"]
desc "Run specs"
-Spec::Rake::SpecTask.new do |t|
- t.spec_files = spec_files
- t.spec_opts = ["-c"]
+RSpec::Core::RakeTask.new(:spec) do |t|
+ t.pattern = "spec/**/*_spec.rb"
end
Cucumber::Rake::Task.new(:features) do |t|
View
10 features/step_definitions/interaction_steps.rb
@@ -1,9 +1,9 @@
Given /^a profile named "([^\"]*)" on "([^\"]*)"$/ do |name, tower|
- When 'I run rubywarrior'
- And 'I answer "y" to "create one?"'
- And 'I choose "' + tower + '" for "tower"'
- And 'I answer "' + name + '" to "name"'
- Then 'I should see "generated"'
+ step 'I run rubywarrior'
+ step 'I answer "y" to "create one?"'
+ step 'I choose "' + tower + '" for "tower"'
+ step 'I answer "' + name + '" to "name"'
+ step 'I should see "generated"'
end
Given /^no profile at "([^\"]*)"$/ do |path|
View
2  features/support/env.rb
@@ -1,5 +1,5 @@
require 'cucumber'
-require 'spec'
+require 'rspec'
require File.dirname(__FILE__) + '/../../lib/ruby_warrior'
View
2  spec/ruby_warrior/abilities/attack_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Attack do
before(:each) do
View
2  spec/ruby_warrior/abilities/base_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Base do
before(:each) do
View
2  spec/ruby_warrior/abilities/bind_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Bind do
before(:each) do
View
2  spec/ruby_warrior/abilities/direction_of_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::DirectionOf do
before(:each) do
View
2  spec/ruby_warrior/abilities/direction_of_stairs_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::DirectionOfStairs do
before(:each) do
View
2  spec/ruby_warrior/abilities/distance_of_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::DistanceOf do
before(:each) do
View
2  spec/ruby_warrior/abilities/explode_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Explode do
before(:each) do
View
2  spec/ruby_warrior/abilities/feel_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Feel do
before(:each) do
View
2  spec/ruby_warrior/abilities/form_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Form do
before(:each) do
View
2  spec/ruby_warrior/abilities/health_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Health do
before(:each) do
View
2  spec/ruby_warrior/abilities/listen_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Listen do
before(:each) do
View
2  spec/ruby_warrior/abilities/look_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Look do
before(:each) do
View
2  spec/ruby_warrior/abilities/pivot_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Pivot do
before(:each) do
View
2  spec/ruby_warrior/abilities/rescue_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Rescue do
before(:each) do
View
2  spec/ruby_warrior/abilities/rest_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Rest do
before(:each) do
View
2  spec/ruby_warrior/abilities/shoot_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Shoot do
before(:each) do
View
2  spec/ruby_warrior/abilities/throw_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Detonate do
before(:each) do
View
2  spec/ruby_warrior/abilities/walk_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Abilities::Walk do
before(:each) do
View
2  spec/ruby_warrior/core_additions_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe String do
it "should wrap text at white space when over a specific character length" do
View
2  spec/ruby_warrior/floor_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Floor do
describe "2x3" do
View
2  spec/ruby_warrior/game_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Game do
before(:each) do
View
2  spec/ruby_warrior/level_loader_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::LevelLoader do
describe "with profile" do
View
2  spec/ruby_warrior/level_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
require 'set'
describe RubyWarrior::Level do
View
2  spec/ruby_warrior/player_generator_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::PlayerGenerator do
before(:each) do
View
2  spec/ruby_warrior/position_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Position do
before(:each) do
View
2  spec/ruby_warrior/profile_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Profile do
before(:each) do
View
2  spec/ruby_warrior/space_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Space do
before(:each) do
View
2  spec/ruby_warrior/tower_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Tower do
before(:each) do
View
2  spec/ruby_warrior/turn_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Turn do
describe "with actions" do
View
2  spec/ruby_warrior/ui_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../spec_helper'
+require 'spec_helper'
describe RubyWarrior::UI do
before(:each) do
View
2  spec/ruby_warrior/units/archer_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Units::Archer do
before(:each) do
View
2  spec/ruby_warrior/units/base_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Units::Base do
before(:each) do
View
2  spec/ruby_warrior/units/captive_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Units::Captive do
before(:each) do
View
2  spec/ruby_warrior/units/golem_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Units::Golem do
before(:each) do
View
2  spec/ruby_warrior/units/sludge_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Units::Sludge do
before(:each) do
View
2  spec/ruby_warrior/units/thick_sludge_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Units::ThickSludge do
before(:each) do
View
2  spec/ruby_warrior/units/warrior_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
class Player
def turn(warrior)
View
2  spec/ruby_warrior/units/wizard_spec.rb
@@ -1,4 +1,4 @@
-require File.dirname(__FILE__) + '/../../spec_helper'
+require 'spec_helper'
describe RubyWarrior::Units::Wizard do
before(:each) do
View
4 spec/spec_helper.rb
@@ -1,8 +1,8 @@
require 'rubygems'
-require 'spec'
+require 'rspec'
require File.dirname(__FILE__) + '/../lib/ruby_warrior'
-Spec::Runner.configure do |config|
+RSpec.configure do |config|
config.mock_with :mocha
config.before(:each) do
RubyWarrior::Config.reset
View
2  towers/intermediate/level_003.rb
@@ -5,7 +5,7 @@
# ---
description "You feel slime on all sides, you're surrounded!"
-tip "Call warrior.bind!(direction) to bind an enemy to keep him from attacking. Bound enemies look like capitves."
+tip "Call warrior.bind!(direction) to bind an enemy to keep him from attacking. Bound enemies look like captives."
clue "Count the number of enemies around you, if there's two or more, bind one."
time_bonus 50

No commit comments for this range

Something went wrong with that request. Please try again.