TestShell documentation mentions a TestShell.reset()
method.
When experimenting with it, it will always fail with:
0Traceback (most recent call last):
1 File "/Users/jose.edil/2-development/bitcoin/vinteum/foss-program/infra-signet-server/signet-server.py", line 169, in <module>
2 TestShell().reset()
3 File "/Users/jose.edil/2-development/bitcoin/bitcoin-core-build/test/functional/test_framework/test_shell.py", line 64, in reset
4 super().__init__()
5TypeError: BitcoinTestFramework.__init__() missing 1 required positional argument: 'test_file'
Indeed, inspecting the source code, we see that TestShell
is a wrapper class for BitcoinTestFramework
. TestShell.reset()
will call super().__init__()
which refers to BitcoinTestFramework.__init__()
.
But we only have def __init__(self, test_file) -> None:
which will require a mandatory test_file
parameter. (https://github.com/bitcoin/bitcoin/blob/28ce159bc327e6dfec34077ff2e379b23a95db65/test/functional/test_framework/test_framework.py#L95C5-L95C43).
Not sure if TestShell.reset()
should change to receive this parameter and pass along to the __init__()
function it calls internally or any other workaround. In my specific case, I can’t see what I can pass as test_file
.