Class Bacon::TestUnitOutput::Proc
In: lib/bacon.rb
Parent: Object

Methods

change?   raise?   throw?  

Public Instance methods

[Source]

     # File lib/bacon.rb, line 229
229:   def change?
230:     pre_result = yield
231:     called = call
232:     post_result = yield
233:     pre_result != post_result
234:   end

[Source]

     # File lib/bacon.rb, line 205
205:   def raise?(*exceptions)
206:     exceptions = [RuntimeError]  if exceptions.empty?
207:     call
208: 
209:   # Only to work in 1.9.0, rescue with splat doesn't work there right now
210:   rescue Object => e
211:     case e
212:     when *exceptions
213:       e
214:     else
215:       raise e
216:     end
217:   else
218:     false
219:   end

[Source]

     # File lib/bacon.rb, line 221
221:   def throw?(sym)
222:     catch(sym) {
223:       call
224:       return false
225:     }
226:     return true
227:   end

[Validate]