Make FileWrapper iterable
Fix test_shared_data_middleware test case