Fix: Added tests for checking that scope isn't accidentally global on private functions