class SpectatorTestContext
Overview
Class used as the base for all specs using the DSL.
It adds methods and macros necessary to use the DSL from the spec.
This type is intentionally outside the Spectator module.
The reason for this is to prevent name collision when using the DSL to define a spec.
Included Modules
- Spectator::DSL::Concise
- Spectator::DSL::Examples
- Spectator::DSL::Expectations
- Spectator::DSL::Groups
- Spectator::DSL::Hooks
- Spectator::DSL::Matchers
- Spectator::DSL::Memoize
- Spectator::DSL::Mocks
Defined in:
spectator/test_context.crInstance methods inherited from module Spectator::DSL::Mocks
  
  
    
      allow(stubbable : Stubbable | StubbedType)allow(stubbable) allow, any_args any_args, no_args no_args
Instance methods inherited from module Spectator::DSL::Expectations
  
  
    
      aggregate_failures(label = nil, &)
    aggregate_failures, 
    
  
    
      fail(message = "Example failed", *, _file = __FILE__, _line = __LINE__)
    fail, 
    
  
    
      pending(message = PendingResult::DEFAULT_REASON, *, _file = __FILE__, _line = __LINE__)
    pending, 
    
  
    
      skip(message = PendingResult::DEFAULT_REASON, *, _file = __FILE__, _line = __LINE__)
    skip
    
  
    
    
  
    
    
    
  
    
    
    
  
    
    
    
  
    
  Instance methods inherited from class SpectatorContext
  
  
    
      eval(&)
    eval, 
    
  
    
      inspect(io : IO) : Nil
    inspect, 
    
  
    
      to_s(io : IO) : Nil
    to_s
    
  
    
    
  
    
    
    
  
    
  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