blob: 6bb90bab0e667e538fd9e0848b6eccff3c2d5a5b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
require "command_processor"
describe CommandProcessor do
before(:each) do
@sut = CommandProcessor.new
end
describe "when run" do
it "should run each command added to the queue" do
@first_command.received(:run).wont_be_nil
@second_command.received(:run).wont_be_nil
end
before do
@first_command = fake
@second_command = fake
@sut.add(@first_command)
@sut.add(@second_command)
@sut.run
end
end
end
|