spec/ruby_ext/must_spec.rb in ruby-ext-0.4.1 vs spec/ruby_ext/must_spec.rb in ruby-ext-0.4.2

- old
+ new

@@ -1,23 +1,29 @@ -require "#{File.dirname __FILE__}/../ruby_ext_spec_helper" +require "#{File.dirname __FILE__}/helper" +require "ruby_ext/array" require "ruby_ext/must" describe 'Assert' do it 'must & must_not' do lambda{must_be.never_called}.should raise_error(/ever/) lambda{nil.must_not_be.nil}.should raise_error(/nil/) 1.must_not_be.nil 1.must_be.== 1 lambda{1.must_be.== 2}.should raise_error(%r{==}) 1.must_be.in 1, 2 + 0.must_be.in 0..1 "".must_be.a String 1.must_be.< 2 end it 'must_be & must_not_be' do [].must_be.empty [''].must_not_be.empty lambda{[''].must_be.empty}.should raise_error(/must be/) lambda{[].must_not_be.empty}.should raise_error(/must not be/) + end + + it "should return result" do + [].must_be.empty.should == [] end end \ No newline at end of file