abstract struct Spectator::TestExpression(T)
- Spectator::TestExpression(T)
- Struct
- Value
- Object
Overview
Base type for capturing an expression from a test.
Direct Known Subclasses
Defined in:
spectator/test_expression.crConstructors
-
.new(label : String)
Creates the common base of the expression.
Instance Method Summary
-
#label : String
User-friendly string displayed for the actual expression being tested.
-
#to_s(io)
String representation of the expression.
- #value : T
Instance methods inherited from class Object
should(matcher)
should,
should_eventually(matcher)
should_eventually,
should_never(matcher)
should_never,
should_not(matcher)
should_not
Constructor Detail
Instance Method Detail
def label : String
#
User-friendly string displayed for the actual expression being tested. For instance, in the expectation:
expect(foo).to eq(bar)
This property will be "foo". It will be the literal string "foo", and not the actual value of the foo.