class MarkdownExec::TestHashDelegator::TestHashDelegatorBlockFind

def setup

def setup
  @hd = HashDelegator.new
end

def test_block_find_with_default

def test_block_find_with_default
  blocks = [{ key: 'value1' }, { key: 'value2' }]
  result = HashDelegator.block_find(blocks, :key, 'value3', 'default')
  assert_equal 'default', result
end

def test_block_find_with_match

def test_block_find_with_match
  blocks = [{ key: 'value1' }, { key: 'value2' }]
  result = HashDelegator.block_find(blocks, :key, 'value1')
  assert_equal({ key: 'value1' }, result)
end

def test_block_find_without_match

def test_block_find_without_match
  blocks = [{ key: 'value1' }, { key: 'value2' }]
  result = HashDelegator.block_find(blocks, :key, 'value3')
  assert_nil result
end