summaryrefslogtreecommitdiff
path: root/spec/console_specs.rb
blob: cab9c8ed6f01365afc38f43dc076928f8c1dab61 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
require "console"

describe Console do
  before do
    @input = fake
    @output = fake
    @presenter = fake
    @sut = Console.new(@input, @output)
  end
  describe "when run" do
    it "should ask for the size of the terrain" do
      #@output.received(:puts).called_with("Please enter the size of the terrain:").wont_be_nil
    end
    it "should create the terrain" do
      #@presenter.received(:provide_upper_right_coordinates).called_with("5 5").wont_be_nil
    end
    before do
      @input.stub(:gets).and_return("5 5")
      #@sut.run(@presenter)
    end
  end
end