class Spectator::Spec
- Spectator::Spec
- Reference
- Object
Overview
Contains examples to be tested and configuration for running them.
Defined in:
spectator/spec.crConstructors
-
.new(root : ExampleGroup, config : Config)
Creates the spec.
Instance Method Summary
-
#run : Bool
Runs all selected examples and returns the results.
Instance methods inherited from class Object
should(matcher : Spectator::Matchers::TypeMatcher(U), message = nil, *, _file = __FILE__, _line = __LINE__) forall Ushould(matcher, message = nil, *, _file = __FILE__, _line = __LINE__) should, should_eventually(matcher, message = nil, *, _file = __FILE__, _line = __LINE__) should_eventually, should_never(matcher, message = nil, *, _file = __FILE__, _line = __LINE__) should_never, should_not(matcher : Spectator::Matchers::TypeMatcher(U), message = nil, *, _file = __FILE__, _line = __LINE__) forall U
should_not(matcher : Spectator::Matchers::NilMatcher, message = nil, *, _file = __FILE__, _line = __LINE__)
should_not(matcher, message = nil, *, _file = __FILE__, _line = __LINE__) should_not
Constructor Detail
Creates the spec. The root is the top-most example group. All examples in this group and groups nested under are candidates for execution. The config provides settings controlling how tests will be executed.
Instance Method Detail
def run : Bool
#
Runs all selected examples and returns the results. True will be returned if the spec ran successfully, or false if there was at least one failure.