Tests for variable scoping (todos)