spec/applix_spec.rb in applix-0.4.6 vs spec/applix_spec.rb in applix-0.4.7
- old
+ new
@@ -116,10 +116,11 @@
end
it 'runs epilog callback after handle' do
t_handle = Applix.main([:func]) do
epilog { |rc, *_|
+ sleep 0.1
$t_post_handle = Time.now
rc
}
handle(:func) {
# epilog block should not have been executed yet
@@ -127,10 +128,11 @@
Time.now
}
end
t_handle.should_not == nil
$t_post_handle.should_not == nil
- (t_handle < $t_post_handle).should == true
+ #(t_handle < $t_post_handle).should == true
+ t_handle.should be < $t_post_handle
end
it 'supports :any as fallback on command lines without matching task' do
Applix.main(%w(--opt1 foo param1 param2), {:opt2 => false}) do
handle(:not_called) { raise "can't possible happen" }