b2580c79d7
Network disconnect is introduced by removing default gateway, easily reversible condition. On my local machine it takes 30 seconds for peers to reconnect after connectivity is restored. As you guess this is not an accident, and there is 30 seconds timeout for dial expiration. This dial expiration is used in p2p.Server to guarantee that peers are not dialed too often. Additionally I added small script to Makefile to run such tests in docker environment, usage example: ``` make docker-test ARGS="./t/destructive/ -v -network=4" ``` |
||
---|---|---|
.. | ||
README.md | ||
peers_test.go | ||
testcontroller.go |
README.md
Destructive tests
The goal is to test behaviour of status-go and underlying protocols under erroneous conditions, such as losing network connection.
Test could cause unpredictable side effects, such as change of network configuration. I don't advice to run them locally on your machine, just use docker container. Also note that tests are relying on real data, such as number of peers.
make docker-test ARGS="./t/destructive/ -v -network=3"