Author: Rusty Russell 2015-09-30 04:16:24
Published on: 2015-09-30T04:16:24+00:00
In this email conversation, Rusty Russell is discussing state coverage testing with Anthony Towns. Rusty mentions that the testing isn't exhaustive and only serves to ensure that the state machine doesn't crash. He lists the varying degrees of thoroughness of the tests, which include ensuring that the state machine never gets into an invalid state, never sends a packet the other side doesn't expect, terminates if not on the main loop, does not deadlock, and cleans up. Anthony asks about testing agreeing on two HTLCs and having one time out before the other. Rusty responds that STATE_CLOSED means "completely finished" and that they don't support mutual close with outstanding HTLCs because the protocol is complex enough already. He also suggests adding optional output of traces for successful test cases to make it more obvious what's being tested. Rusty concludes by saying that while more comments and testing would be nice, he has to stop writing tests at some point.
Updated on: 2023-05-23T20:53:31.696939+00:00