Class: Minitest::Proptest::Status

Inherits:
Object
  • Object
show all
Defined in:
lib/minitest/proptest/status.rb

Overview

Sum type representing the possible statuses of a test run. Invalid, Overrun, and Interesting represent different failure classes. Unknown represents a lack of information about the test run (typically having not run to satisfaction). Valid represents a test which has run to satisfaction.

Direct Known Subclasses

Interesting, Invalid, Overrun, Unknown, Valid

Defined Under Namespace

Classes: Interesting, Invalid, Overrun, Unknown, Valid

Instance Method Summary collapse

Constructor Details

#initializeStatus

Returns a new instance of Status.



58
59
60
# File 'lib/minitest/proptest/status.rb', line 58

def initialize
  raise 'Please use singleton instances'
end

Instance Method Details

#interesting?Boolean

Returns:

  • (Boolean)


54
55
56
# File 'lib/minitest/proptest/status.rb', line 54

def interesting?
  self.is_a?(Interesting)
end

#invalid?Boolean

Returns:

  • (Boolean)


38
39
40
# File 'lib/minitest/proptest/status.rb', line 38

def invalid?
  self.is_a?(Invalid)
end

#overrun?Boolean

Returns:

  • (Boolean)


42
43
44
# File 'lib/minitest/proptest/status.rb', line 42

def overrun?
  self.is_a?(Overrun)
end

#unknown?Boolean

Returns:

  • (Boolean)


46
47
48
# File 'lib/minitest/proptest/status.rb', line 46

def unknown?
  self.is_a?(Unknown)
end

#valid?Boolean

Returns:

  • (Boolean)


50
51
52
# File 'lib/minitest/proptest/status.rb', line 50

def valid?
  self.is_a?(Valid)
end