Module: Test::Unit::TestResultNotificationSupport

Included in:
TestResult
Defined in:
lib/test/unit/notification.rb

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Instance Attribute Details

- (Object) notifications (readonly)

Returns the value of attribute notifications



109
110
111
# File 'lib/test/unit/notification.rb', line 109

def notifications
  @notifications
end

Instance Method Details

- (Object) add_notification(notification)

Records a Test::Unit::Notification.



112
113
114
115
116
# File 'lib/test/unit/notification.rb', line 112

def add_notification(notification)
  @notifications << notification
  notify_fault(notification)
  notify_changed
end

- (Object) notification_count

Returns the number of notifications this TestResult has recorded.



120
121
122
# File 'lib/test/unit/notification.rb', line 120

def notification_count
  @notifications.size
end