Class: Shoes::SpecInstance
- Inherits:
-
Object
- Object
- Shoes::SpecInstance
- Defined in:
- lacci/lib/shoes-spec.rb
Overview
ShoesSpec testing objects can optionally inherit from this object, which shows the ShoesSpec testing API.
Instance Method Summary collapse
-
#run_shoes_spec_test_code(code, class_name: nil, test_name: nil) ⇒ void
Once a Shoes app has been created, this method can be called to execute Shoes-Spec testing code for that application.
Instance Method Details
#run_shoes_spec_test_code(code, class_name: nil, test_name: nil) ⇒ void
This method returns an undefined value.
Once a Shoes app has been created, this method can be called to execute Shoes-Spec testing code for that application. Shoes-Spec uses Minitest for most of its APIs, and Minitest generally reports results with a class name and test name. If those aren't passed explicitly, the SpecInstance can choose reasonable defaults.
The test code should be set up to run automatically from the display service's existing hooks. For instance, the code might run in response to the first heartbeat, if the display service uses heartbeats.
The test code will export assertion data in its native format. Multiple display services choose to use the Scarpe-Component for Minitest data export, which is straightforward to import into the Shoes-Spec test harness.
47 48 49 |
# File 'lacci/lib/shoes-spec.rb', line 47 def run_shoes_spec_test_code(code, class_name: nil, test_name: nil) raise "Child class should override this!" end |