From 64166d1c363e3fe277173dc6e1ad7a7b3171b59d Mon Sep 17 00:00:00 2001 From: Michael Miller Date: Wed, 11 Sep 2019 22:21:06 -0600 Subject: [PATCH] Some fixes --- src/spectator/example.cr | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/spectator/example.cr b/src/spectator/example.cr index 78712ed..3b5cbb2 100644 --- a/src/spectator/example.cr +++ b/src/spectator/example.cr @@ -1,4 +1,5 @@ require "./example_component" +require "./test_wrapper" module Spectator # Base class for all types of examples. @@ -11,7 +12,7 @@ module Spectator getter group : ExampleGroup # Retrieves the internal wrapped instance. - private getter @test_wrapper : TestWrapper + private getter test_wrapper : TestWrapper # Source where the example originated from. def source @@ -22,6 +23,11 @@ module Spectator @test_wrapper.description end + def symbolic? + description = @test_wrapper.description + description.start_with?('#') || description.start_with?('.') + end + # Runs the example code. # A result is returned, which represents the outcome of the test. # An example can be run only once.