failing test for mocking unqualified functions in top environment