ibis
ibis copied to clipboard
feat(dev): pytest failure hook to show generated sql
trafficstars
We interact with a LOT of systems, sometimes in succession, and it can be hard to reproduce some test failures.
I think we should add a pytest hook that, upon test failure, we dump any compiled SQL to stderr or stdout so that we can manually inspect it. That will (hopefully) allow us to discern whether Ibis did something silly or whether the backend is doing something silly / unpredictable, so we know how to focus our efforts.
Also, whether this is the same hook / plugin or an additional one, we should dump the random seed used into each test failure message so we can easily find it if the traceback is long.