diff --git a/.gitignore b/.gitignore index 38f977c6..d8a14f21 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,5 @@ tmp/**/* *.gem +.project +.buildpath +Gemfile.lock \ No newline at end of file diff --git a/features/step_definitions/interaction_steps.rb b/features/step_definitions/interaction_steps.rb index 5c1b50ee..be2b1077 100644 --- a/features/step_definitions/interaction_steps.rb +++ b/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| diff --git a/spec/ruby_warrior/abilities/attack_spec.rb b/spec/ruby_warrior/abilities/attack_spec.rb index 5a24fdb7..d684253d 100644 --- a/spec/ruby_warrior/abilities/attack_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/base_spec.rb b/spec/ruby_warrior/abilities/base_spec.rb index d460b0f1..d833c22f 100644 --- a/spec/ruby_warrior/abilities/base_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/bind_spec.rb b/spec/ruby_warrior/abilities/bind_spec.rb index 239dae13..f30a23d6 100644 --- a/spec/ruby_warrior/abilities/bind_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/direction_of_spec.rb b/spec/ruby_warrior/abilities/direction_of_spec.rb index 0ea671ef..8a6d9d4e 100644 --- a/spec/ruby_warrior/abilities/direction_of_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/direction_of_stairs_spec.rb b/spec/ruby_warrior/abilities/direction_of_stairs_spec.rb index 71aa4fbe..76b2b6c1 100644 --- a/spec/ruby_warrior/abilities/direction_of_stairs_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/distance_of_spec.rb b/spec/ruby_warrior/abilities/distance_of_spec.rb index 9c0d94ce..0faddf97 100644 --- a/spec/ruby_warrior/abilities/distance_of_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/explode_spec.rb b/spec/ruby_warrior/abilities/explode_spec.rb index 7b384707..bf4d7e6c 100644 --- a/spec/ruby_warrior/abilities/explode_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/feel_spec.rb b/spec/ruby_warrior/abilities/feel_spec.rb index 01f43bae..9b413b7a 100644 --- a/spec/ruby_warrior/abilities/feel_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/form_spec.rb b/spec/ruby_warrior/abilities/form_spec.rb index 690a5735..9407dca3 100644 --- a/spec/ruby_warrior/abilities/form_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/health_spec.rb b/spec/ruby_warrior/abilities/health_spec.rb index 7d20c5f8..95a8f7b5 100644 --- a/spec/ruby_warrior/abilities/health_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/listen_spec.rb b/spec/ruby_warrior/abilities/listen_spec.rb index 266d842d..39ad2283 100644 --- a/spec/ruby_warrior/abilities/listen_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/look_spec.rb b/spec/ruby_warrior/abilities/look_spec.rb index ef771a8f..e94ba387 100644 --- a/spec/ruby_warrior/abilities/look_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/pivot_spec.rb b/spec/ruby_warrior/abilities/pivot_spec.rb index 3261973e..da6feb85 100644 --- a/spec/ruby_warrior/abilities/pivot_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/rescue_spec.rb b/spec/ruby_warrior/abilities/rescue_spec.rb index a4a154ac..fe7f032b 100644 --- a/spec/ruby_warrior/abilities/rescue_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/rest_spec.rb b/spec/ruby_warrior/abilities/rest_spec.rb index a77b0f55..33f64ac1 100644 --- a/spec/ruby_warrior/abilities/rest_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/shoot_spec.rb b/spec/ruby_warrior/abilities/shoot_spec.rb index aad89a22..b5bb8c2e 100644 --- a/spec/ruby_warrior/abilities/shoot_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/throw_spec.rb b/spec/ruby_warrior/abilities/throw_spec.rb index 24d7b2a1..3dffdd35 100644 --- a/spec/ruby_warrior/abilities/throw_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/abilities/walk_spec.rb b/spec/ruby_warrior/abilities/walk_spec.rb index b8c1de6d..921d64de 100644 --- a/spec/ruby_warrior/abilities/walk_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/core_additions_spec.rb b/spec/ruby_warrior/core_additions_spec.rb index beb18d89..21bc697a 100644 --- a/spec/ruby_warrior/core_additions_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/floor_spec.rb b/spec/ruby_warrior/floor_spec.rb index ae72cc8c..ad0435df 100644 --- a/spec/ruby_warrior/floor_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/game_spec.rb b/spec/ruby_warrior/game_spec.rb index b7314d4d..8d4e1bad 100644 --- a/spec/ruby_warrior/game_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/level_loader_spec.rb b/spec/ruby_warrior/level_loader_spec.rb index 63e3b477..f02b3c96 100644 --- a/spec/ruby_warrior/level_loader_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/level_spec.rb b/spec/ruby_warrior/level_spec.rb index 7fdf4cd4..72a5856d 100644 --- a/spec/ruby_warrior/level_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/player_generator_spec.rb b/spec/ruby_warrior/player_generator_spec.rb index e3d6c17a..b4eb9d39 100644 --- a/spec/ruby_warrior/player_generator_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/position_spec.rb b/spec/ruby_warrior/position_spec.rb index 932a84e1..d155f7c5 100644 --- a/spec/ruby_warrior/position_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/profile_spec.rb b/spec/ruby_warrior/profile_spec.rb index 266c0a15..a2137907 100644 --- a/spec/ruby_warrior/profile_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/space_spec.rb b/spec/ruby_warrior/space_spec.rb index 4856eb75..869a995b 100644 --- a/spec/ruby_warrior/space_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/tower_spec.rb b/spec/ruby_warrior/tower_spec.rb index 2ff35b2c..f42840c0 100644 --- a/spec/ruby_warrior/tower_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/turn_spec.rb b/spec/ruby_warrior/turn_spec.rb index 4bd11d02..c45f11de 100644 --- a/spec/ruby_warrior/turn_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/ui_spec.rb b/spec/ruby_warrior/ui_spec.rb index 20dff062..52f8f817 100644 --- a/spec/ruby_warrior/ui_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/units/archer_spec.rb b/spec/ruby_warrior/units/archer_spec.rb index daadcf14..2f5820d7 100644 --- a/spec/ruby_warrior/units/archer_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/units/base_spec.rb b/spec/ruby_warrior/units/base_spec.rb index ce9c1169..ec5c2c76 100644 --- a/spec/ruby_warrior/units/base_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/units/captive_spec.rb b/spec/ruby_warrior/units/captive_spec.rb index 46fe37a1..cda46c22 100644 --- a/spec/ruby_warrior/units/captive_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/units/golem_spec.rb b/spec/ruby_warrior/units/golem_spec.rb index a4dfc48c..bd69d40a 100644 --- a/spec/ruby_warrior/units/golem_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/units/sludge_spec.rb b/spec/ruby_warrior/units/sludge_spec.rb index db1c1e67..898fd7b0 100644 --- a/spec/ruby_warrior/units/sludge_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/units/thick_sludge_spec.rb b/spec/ruby_warrior/units/thick_sludge_spec.rb index f0f9c9a8..8d790fa5 100644 --- a/spec/ruby_warrior/units/thick_sludge_spec.rb +++ b/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 diff --git a/spec/ruby_warrior/units/warrior_spec.rb b/spec/ruby_warrior/units/warrior_spec.rb index 17c59781..276897b4 100644 --- a/spec/ruby_warrior/units/warrior_spec.rb +++ b/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) diff --git a/spec/ruby_warrior/units/wizard_spec.rb b/spec/ruby_warrior/units/wizard_spec.rb index 27966dcf..b4a582d0 100644 --- a/spec/ruby_warrior/units/wizard_spec.rb +++ b/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