summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
Diffstat (limited to 'spec')
-rw-r--r--spec/rover_specs.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/spec/rover_specs.rb b/spec/rover_specs.rb
index a54e2c2..9dc73d0 100644
--- a/spec/rover_specs.rb
+++ b/spec/rover_specs.rb
@@ -2,7 +2,8 @@ require 'rover'
describe Rover do
def create_sut(heading, x = 0, y = 0)
- Rover.new heading,{ :x =>x,:y => y }
+ directions = {:north => North.new, :east => East.new, :west => West.new, :south => South.new}
+ Rover.new directions[heading],{ :x =>x,:y => y }
end
describe "when facing north" do