Undefined variable
https://github.com/pandas-dev/pandas/blob/99cf794ae2f63f3137290e7df59b1d31b22ae3d3/pandas/tests/test_common.py#L28

```
  class somecall:
        def __call__(self):
            return x  # noqa
    assert getname(fn) == "fn"
    assert getname(lambda_)
    assert getname(part1) == "fn"
    assert getname(part2) == "fn"
    assert getname(somecall()) == "somecall"
    assert getname(1) is None
```

It looks like the statement inside  __call__ function does not have x defined first.

