Tests for issues with default args in dynamic param contexts.
Only real modules should be added in get_modules_containing_name.
Fix obvious UnboundLocalError.