Class: MarkdownExec::TestMDocCollectDependencies
- Defined in:
- lib/mdoc.rb
Instance Method Summary collapse
- #setup ⇒ Object
- #test_collect_dependencies_with_no_source ⇒ Object
- #test_collect_dependencies_with_valid_source ⇒ Object
Instance Method Details
#test_collect_dependencies_with_no_source ⇒ Object
386 387 388 |
# File 'lib/mdoc.rb', line 386 def test_collect_dependencies_with_no_source assert_empty @mdoc.collect_dependencies(nil) end |
#test_collect_dependencies_with_valid_source ⇒ Object
396 397 398 399 400 401 402 |
# File 'lib/mdoc.rb', line 396 def test_collect_dependencies_with_valid_source @mdoc.stubs(:get_block_by_anyname).with('source1').returns({ reqs: ['source2'] }) @mdoc.stubs(:get_block_by_anyname).with('source2').returns({ reqs: [] }) expected = { 'source1' => ['source2'], 'source2' => [] } assert_equal expected, @mdoc.collect_dependencies('source1') end |