Class: Tryouts::OutputExpectation

Inherits:
Data
  • Object
show all
Defined in:
lib/tryouts/test_case.rb

Overview

Special expectation type for output capturing with pipe information

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#contentObject (readonly)

Returns the value of attribute content

Returns:

  • (Object)

    the current value of content



61
62
63
# File 'lib/tryouts/test_case.rb', line 61

def content
  @content
end

#pipeObject (readonly)

Returns the value of attribute pipe

Returns:

  • (Object)

    the current value of pipe



61
62
63
# File 'lib/tryouts/test_case.rb', line 61

def pipe
  @pipe
end

#typeObject (readonly)

Returns the value of attribute type

Returns:

  • (Object)

    the current value of type



61
62
63
# File 'lib/tryouts/test_case.rb', line 61

def type
  @type
end

Instance Method Details

#boolean?Boolean

Returns:

  • (Boolean)


64
# File 'lib/tryouts/test_case.rb', line 64

def boolean? = type == :boolean

#exception?Boolean

Returns:

  • (Boolean)


63
# File 'lib/tryouts/test_case.rb', line 63

def exception? = type == :exception

#false?Boolean

Returns:

  • (Boolean)


66
# File 'lib/tryouts/test_case.rb', line 66

def false? = type == :false

#intentional_failure?Boolean

Returns:

  • (Boolean)


70
# File 'lib/tryouts/test_case.rb', line 70

def intentional_failure? = type == :intentional_failure

#output?Boolean

Returns:

  • (Boolean)


71
# File 'lib/tryouts/test_case.rb', line 71

def output? = type == :output

#performance_time?Boolean

Returns:

  • (Boolean)


69
# File 'lib/tryouts/test_case.rb', line 69

def performance_time? = type == :performance_time

#regex_match?Boolean

Returns:

  • (Boolean)


68
# File 'lib/tryouts/test_case.rb', line 68

def regex_match? = type == :regex_match

#regular?Boolean

Returns:

  • (Boolean)


62
# File 'lib/tryouts/test_case.rb', line 62

def regular? = type == :regular

#result_type?Boolean

Returns:

  • (Boolean)


67
# File 'lib/tryouts/test_case.rb', line 67

def result_type? = type == :result_type

#stderr?Boolean

Returns:

  • (Boolean)


74
# File 'lib/tryouts/test_case.rb', line 74

def stderr? = pipe == 2

#stdout?Boolean

Returns:

  • (Boolean)


73
# File 'lib/tryouts/test_case.rb', line 73

def stdout? = pipe == 1

#true?Boolean

Returns:

  • (Boolean)


65
# File 'lib/tryouts/test_case.rb', line 65

def true? = type == :true