diff options
| author | mo k <mo@mokhan.ca> | 2012-02-16 23:32:42 -0700 |
|---|---|---|
| committer | mo k <mo@mokhan.ca> | 2012-02-16 23:32:42 -0700 |
| commit | 272c52e0402378d209e96af29a6edce963d8868c (patch) | |
| tree | b68ef4a6c276ec3cfc19e4a1ae79ac191d8e139f /spec/anonymous_command_specs.rb | |
| parent | faa9af85891ceee8ea87e01b5b4412d6aa6cbc55 (diff) | |
create anonymous command.
Diffstat (limited to 'spec/anonymous_command_specs.rb')
| -rw-r--r-- | spec/anonymous_command_specs.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/spec/anonymous_command_specs.rb b/spec/anonymous_command_specs.rb new file mode 100644 index 0000000..2616770 --- /dev/null +++ b/spec/anonymous_command_specs.rb @@ -0,0 +1,16 @@ +require "anonymous_command" + +describe AnonymousCommand do + describe "when run" do + it "should run the block" do + assert_equal true, @called + end + before(:each) do + #block = lambda { @called = true } + block = Proc.new { @called = true } + @called = false + @sut = AnonymousCommand.new(block) + @sut.run + end + end +end |
