    def get_txs_patched(conn, **args):
        """Patch `get_transactions_filtered` so that rather than return an array
            of transactions it returns an array of shims with a to_dict() method
            that reports one of the arguments passed to `get_transactions_filtered`.
            """
        return [type('', (), {'to_dict': partial(lambda a: a, arg)})
                for arg in sorted(args.items())]
Patch `get_transactions_filtered` so that rather than return an array
of transactions it returns an array of shims with a to_dict() method
that reports one of the arguments passed to `get_transactions_filtered`.
tests/web/test_transactions.py