simperby icon indicating copy to clipboard operation
simperby copied to clipboard

Define unit tests for peer discovery without internet

Open junha1 opened this issue 2 years ago • 4 comments

junha1 avatar Jul 16 '22 01:07 junha1

It seems we have two options when running the tests on the same machine:

  • to create multiple r/w streams in the same (OS) process and let them communicate with each other
  • to create a single r/w stream in the binary but spawn multiple processes to have separated nodes

The first choice is easier to code, however, the second one is more desirable since we can have logically separated nodes, which resemble the nodes in a local private network.

f2koi avatar Jul 16 '22 04:07 f2koi

I think we will have bunch of e2e tests that covers the second options. Let's stick to the first one so that we can focus on the 'logic', not the lower level network issues.

junha1 avatar Jul 16 '22 04:07 junha1

Basic tests for bootstrapping are included in #41. I plan to add more tests for continuous peer discovery.

f2koi avatar Aug 24 '22 13:08 f2koi

The interface for the network module has been changed. Thus, the network developers(including me) should make new unit tests for the new interface.

f2koi avatar Sep 29 '22 17:09 f2koi