add test for issue118
update tests
add _funcName property
fix bugs in tests
hook type deduction