Added test for closure