fix tests
fix how vars are found in Nodes

Previously I was only looking in Statements, of which only
AssignStatements returned anything. But that missed two cases:
AssignExpressions (which was breaking the invoke-nonvar-on-instance
test) and statements that contain blocks that contain AssignStatements.
So, replace that simplistic var-finding mechanism with a (slightly) more
sophisticated one that uses a recursive vistor. Also add a test for that
nested-statement-with-vars case.