Class: Filet::TestCase
- Inherits:
-
Object
- Object
- Filet::TestCase
- Extended by:
- Backport::Declarative, Hooks
- Defined in:
- lib/filet/test_case.rb
Class Attribute Summary collapse
-
.description ⇒ Object
Returns the value of attribute description.
Class Method Summary collapse
- .background(&block) ⇒ Object
- .context(name, options = {}, &block) ⇒ Object
- .teardown(&block) ⇒ Object
Instance Method Summary collapse
-
#default_test ⇒ Object
Placeholder so test/unit ignores test cases without any tests.
Methods included from Hooks
context_hook, context_hook=, extended, feature_hook, feature_hook=
Methods included from Backport::Declarative
Class Attribute Details
.description ⇒ Object
Returns the value of attribute description.
15 16 17 |
# File 'lib/filet/test_case.rb', line 15 def description @description end |
Class Method Details
.background(&block) ⇒ Object
27 28 29 |
# File 'lib/filet/test_case.rb', line 27 def background(&block) define_method(:setup, &block) end |
.context(name, options = {}, &block) ⇒ Object
19 20 21 22 23 24 25 |
# File 'lib/filet/test_case.rb', line 19 def context(name, = {}, &block) klass = create_class(name, self, &block) context_hook.call(klass, ) if context_hook klass end |
.teardown(&block) ⇒ Object
31 32 33 |
# File 'lib/filet/test_case.rb', line 31 def teardown(&block) define_method(:teardown, &block) end |
Instance Method Details
#default_test ⇒ Object
Placeholder so test/unit ignores test cases without any tests.
38 39 |
# File 'lib/filet/test_case.rb', line 38 def default_test end |