swarm/test: Add integration test for 'swarm up'#14353
Conversation
1670978 to
b8dad6b
Compare
|
I had to update |
swarm/test/cluster.go
Outdated
There was a problem hiding this comment.
There is a non trivial amount of time between exec'ing the process and it listening on the IPC socket, a retry dial loop seems to be the easiest way to wait for that to happen.
swarm/test/cli_test.go
Outdated
There was a problem hiding this comment.
So these are already the kinds of tests i want the network testing framework to do.
Here i assume your objective is just to have basic tests for the CLI itself?
Just wonder how this will align with our scenario driven test framework and if it is worth the effort
maintaining this. Let's have a chat
There was a problem hiding this comment.
These tests are basically just CLI tests yes, which I don't think will be covered by the scenario tests (they most likely won't be calling swarm up, swarm manifest etc.).
My vision is that we have three types of tests:
- Unit tests - testing the behaviour of individual functions / objects
- Integration tests - testing the behaviour from the end user's perspective using compiled binaries / HTTP / IPC requests
- Network scenario tests - testing how the nodes interact with each other at a large scale, running either in-memory / rlpx with unique ports / docker containers / kvm
WDYT?
f488d92 to
61f8f97
Compare
61f8f97 to
3bcacd2
Compare
|
Please fix the cmd/swarm test on windows. |
|
Also, please move "cmd/testutils" to "internal/cmdtest". |
011155d to
1058337
Compare
|
@zelig I have just seen an odd failure in Travis (https://travis-ci.org/ethereum/go-ethereum/jobs/227099226):
Here is the output from the logs: That doesn't seem to make much sense to me, thoughts? |
1058337 to
69c59db
Compare
Signed-off-by: Lewis Marshall <lewis@lmars.net>
Signed-off-by: Lewis Marshall <lewis@lmars.net>
69c59db to
7d08c7a
Compare
|
@fjl I have rebased this and fixed the test on Windows. |
This is a proposal for adding swarm "integration tests" which use a compiled
swarmbinary to boot clusters and upload files, and then make assertions against the HTTP and IPC APIs.This helps us write tests covering the desired behaviour of swarm from the user's point of view (e.g. what does
swarm up file.txtactually do, see #14342).This is as discussed in this weeks swarm standup.
/cc @zelig